Skip to content

gui-assis-zz/ViperTemplate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 

Repository files navigation

ViperTemplate

Viper Template makes the process of generation of the Viper's modules easier and faster.

About Viper

VIPER

In looking for a better way to architect an iOS app I ran across the Clean Architecture, as described by Uncle Bob. Clean Architecture divides an app’s logical structure into distinct layers of responsibility. This makes it easier to isolate dependencies (e.g. your database) and to test the interactions at the boundaries between layers.

VIPER is our application of Clean Architecture to iOS apps. The word VIPER is a backronym for View, Interactor, Presenter, Entity and Routing.

VIPER

  • View — The presentation layer (UI).

  • Interactor — contains business logic related to the data (Entities) or networking, like creating new instances of entities or fetching them from the server. For those purposes you’ll use some Services and Managers which are not considered as a part of VIPER module but rather an external dependency.

  • Presenter — contains the UI related (but UIKit independent) business logic, invokes methods on the Interactor.

  • Entities — your plain data objects, not the data access layer, because that is a responsibility of the Interactor.

  • Router — responsible for the segues and routes between the VIPER modules.

##Viper files

- {{ModuleName}}ViewController.swift
- {{ModuleName}}Interactor.swift
- {{ModuleName}}Presenter.swift
- {{ModuleName}}Model.swift
- {{ModuleName}}Router.swift
- {{ModuleName}}Protocols.swift  

How to install

Clone the repository https://github.com/gui-assis/ViperTemplate.git and run installation script make install_templates

How to use

New File -> Viper -> Module alt tag

References

About

Viper Template makes the process of generation of the Viper's modules easier and faster.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors