A simple OS X App for generating VIPER modules's skeleton to use them in your Objective-C/Swift projects.
============
Get in contact with the developer on Twitter: @same7mabrouk
VIPER is an application of Clean Architecture to iOS apps. The word VIPER is a backronym for View, Interactor, Presenter, Entity, and Routing. 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:
.objc
+-- DataManager
| +-- VIPERDataManager.h
| +-- VIPERDataManager.m
+-- Interactor
| +-- VIPERInteractor.h
| +-- VIPERInteractor.m
+-- Presenter
| +-- VIPERPresenter.h
| +-- VIPERPresenter.m
+-- ViewController
| +-- VIPERViewController.h
| +-- VIPERViewController.m
+-- WireFrame
| +-- VIPERWireFrame.h
| +-- VIPERWireFrame.m
+-- Protocols
| +-- VIPERProtocols.h
.objc tests
+-- Interactor
| +-- VIPERInteractorTests.m
+-- Presenter
| +-- VIPERPresenterTests.m
+-- ViewController
| +-- VIPERViewControllerTests.m
+-- WireFrame
| +-- VIPERWireFrameTests.m
.swift
+-- DataManager
| +-- VIPERDataManager.swift
+-- Interactor
| +-- VIPERInteractor.swift
+-- Presenter
| +-- VIPERPresenter.swift
+-- ViewController
| +-- VIPERViewController.swift
+-- WireFrame
| +-- VIPERWireFrame.swift
+-- Protocols
| +-- VIPERProtocols.swift
.swift tests
+-- Interactor
| +-- VIPERInteractorTests.swift
+-- Presenter
| +-- VIPERPresenterTests.swift
+-- ViewController
| +-- VIPERViewTests.swift
+-- WireFrame
| +-- VIPERWireFrameTests.swift
Just clone the Repo, then build it using xCode 7.2 or above on any Mac OS X 10.10 or above.
Please enter the VIPER module name and module path then click generate button.
And then the files structure will be automatically created. Don't forget to add this folder to your project dragging it into the XCode or Appcode inspector.
Please check "Include unit tests" option then enter the VIPER module name and tests file path then click generate button.
Don't Forget to add dependencies used in the generated code (unit tests classes).
Dependencies List:
Screenshot of the ViperCode OS X app.
Please submit an issue on GitHub, or contact me directly at [email protected]
This project is licensed under the terms of the MIT license. See the LICENSE file.