XCode Templates written with Swift 5
XCode Templates was created to save time for iOS/MacOS developers that are usually spending time copy-pasting same code from another projects just to create new screen with simple UI elements. With XCode Templates this process can be significantly automated.
It automatically creates MVP components for a new screen: programmatical view, view controller, helpers, services, extension, models, etc.
The main idea is to create All-in-One solution where developer will be able to select template, UI framework (UIKit/SwiftUI) and select needed architecture (MVC/MVP/MVVM/VIPER). In every template I’m using only programmatical view, no xib/storyboard.
How to start using
Create “Templates” directory
$ mkdir ~/Library/Developer/Xcode/Templates
Open “Templates” directory that you just created
$ cd ~/Library/Developer/Xcode/Templates
$ git clone https://github.com/mihail-konoplitskyi/4KSOFT-XCode-Templates.git
Restart XCode if it was opened
Open XCode project, press CMD+N, scroll down to 4KSOFT-XCode-Templates and use needed template
Add newly created module to a project
Remove module reference from a project (remove reference, not a directory)
Templates are using different third-party frameworks. You can find installation guide below:
- SnapKit (DSL to make Auto Layout easy on both iOS and OS X)
Empty View Controller
Carousel Collection View
Paging Scroll View
Projects built with XCode Templates
All iOS/MacOS developers are spending tons of time doing absolutely identical work. This repository was created to solve this problem. In a close future I will create most recent templates for developers needs.
After most recent templates will be created with UIKit, I’ll start preparing AppKit templates for MacOS and SwiftUI templates.