Skip to content

87kangsw/ThenGenerator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

64 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ThenGenerator

ThenGenerator

Overview

ThenGenerator is Xcode Source Editor Extension for Then

Install

Download on the Mac App Store

Enviroment

  • macOS 11.0 (Big Sur)
  • SwiftUI
  • UserDefaults

How to use

  1. Install ThenGenerator

  2. Enable Xcode Source Editor

    • -> System Preferences -> Extensions
    • Check ThenGenerator
  3. Input variable name for Generate code. Without UI prefix.

  4. If you want to create a UILabel class with variable name repoNameLabel, you input text VariableName + Label

  5. Select variable name

  6. Editor -> ThenGenerator -> Generate Then Code

Use Shortcut

  1. Xcode Preferences.. ( + ,)
  2. Key Bindings
  3. Search ThenGenerator
  4. Add Shortcut

Change Properties

  1. Launch ThenGeneratorApp
  2. Find UIKit class and turn on/off switch

Demo

Single
Multiline

Contribution

Xcodegen Support

  • Clone -> xcodegen generate

If you find a bug or want to add a new property, find XXXXModel.swift in Models Folder and fix or append property. And find XXXXComponent.swift in ComponentViews Folder and add SwitchView with new property.

References