diff --git a/ViewController.xctemplate/TemplateInfo.plist b/ViewController.xctemplate/TemplateInfo.plist index ce7044d..5e5508a 100644 --- a/ViewController.xctemplate/TemplateInfo.plist +++ b/ViewController.xctemplate/TemplateInfo.plist @@ -60,8 +60,8 @@ -Instantiatable -Instantiatable Injectable + -Instantiatable Emittable -Instantiatable Interactable - -Instantiatable Injectable Interactable diff --git a/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Emittable/___FILEBASENAME___ViewController.swift b/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Emittable/___FILEBASENAME___ViewController.swift new file mode 120000 index 0000000..02668ce --- /dev/null +++ b/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Emittable/___FILEBASENAME___ViewController.swift @@ -0,0 +1 @@ +../ViewController+Emittable.swift \ No newline at end of file diff --git a/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.xib b/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Emittable/___FILEBASENAME___ViewController.xib similarity index 100% rename from ViewController.xctemplate/ViewController with ViewModel-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.xib rename to ViewController.xctemplate/ViewController with ViewModel-Instantiatable Emittable/___FILEBASENAME___ViewController.xib diff --git a/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Injectable Interactable/___FILEBASENAME___ViewModel.swift b/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Emittable/___FILEBASENAME___ViewModel.swift similarity index 100% rename from ViewController.xctemplate/ViewController with ViewModel-Instantiatable Injectable Interactable/___FILEBASENAME___ViewModel.swift rename to ViewController.xctemplate/ViewController with ViewModel-Instantiatable Emittable/___FILEBASENAME___ViewModel.swift diff --git a/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.swift b/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.swift deleted file mode 120000 index a084b20..0000000 --- a/ViewController.xctemplate/ViewController with ViewModel-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.swift +++ /dev/null @@ -1 +0,0 @@ -../ViewController+Injectable+Interactable.swift \ No newline at end of file diff --git a/ViewController.xctemplate/ViewController+Injectable+Interactable.swift b/ViewController.xctemplate/ViewController+Emittable.swift similarity index 80% rename from ViewController.xctemplate/ViewController+Injectable+Interactable.swift rename to ViewController.xctemplate/ViewController+Emittable.swift index 4d73fae..a496fd0 100644 --- a/ViewController.xctemplate/ViewController+Injectable+Interactable.swift +++ b/ViewController.xctemplate/ViewController+Emittable.swift @@ -3,22 +3,13 @@ import UIKit import AppCore -final class ___FILEBASENAME___: UIViewController, Instantiatable, Injectable, Interactable { +final class ___FILEBASENAME___: UIViewController, Instantiatable, Emittable { // MARK: - Mew.Instantiatable typealias Input = <#value#> typealias Environment = EnvironmentProvider var environment: Environment - // MARK: - Mew.Injectable - private var input: Input { - didSet { updateUI() } - } - - func input(_ input: Input) { - self.input = input - } - // MARK: - Mew.Emittable typealias Output = <#value#> private var handler: ((Output) -> Void)? @@ -28,7 +19,6 @@ final class ___FILEBASENAME___: UIViewController, Instantiatable, Injectable, In init(with input: Input, environment: Environment) { self.environment = environment - self.input = input super.init(nibName: nil, bundle: Bundle(for: type(of: self))) } diff --git a/ViewController.xctemplate/ViewController+Interactable.swift b/ViewController.xctemplate/ViewController+Interactable.swift index 854d1eb..e88c0c0 100644 --- a/ViewController.xctemplate/ViewController+Interactable.swift +++ b/ViewController.xctemplate/ViewController+Interactable.swift @@ -10,6 +10,15 @@ final class ___FILEBASENAME___: UIViewController, Instantiatable, Interactable { typealias Environment = EnvironmentProvider var environment: Environment + // MARK: - Mew.Injectable + private var input: Input { + didSet { updateUI() } + } + + func input(_ input: Input) { + self.input = input + } + // MARK: - Mew.Emittable typealias Output = <#value#> private var handler: ((Output) -> Void)? @@ -19,6 +28,7 @@ final class ___FILEBASENAME___: UIViewController, Instantiatable, Interactable { init(with input: Input, environment: Environment) { self.environment = environment + self.input = input super.init(nibName: nil, bundle: Bundle(for: type(of: self))) } diff --git a/ViewController.xctemplate/ViewController-Instantiatable Emittable/___FILEBASENAME___ViewController.swift b/ViewController.xctemplate/ViewController-Instantiatable Emittable/___FILEBASENAME___ViewController.swift new file mode 120000 index 0000000..02668ce --- /dev/null +++ b/ViewController.xctemplate/ViewController-Instantiatable Emittable/___FILEBASENAME___ViewController.swift @@ -0,0 +1 @@ +../ViewController+Emittable.swift \ No newline at end of file diff --git a/ViewController.xctemplate/ViewController-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.xib b/ViewController.xctemplate/ViewController-Instantiatable Emittable/___FILEBASENAME___ViewController.xib similarity index 100% rename from ViewController.xctemplate/ViewController-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.xib rename to ViewController.xctemplate/ViewController-Instantiatable Emittable/___FILEBASENAME___ViewController.xib diff --git a/ViewController.xctemplate/ViewController-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.swift b/ViewController.xctemplate/ViewController-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.swift deleted file mode 120000 index a084b20..0000000 --- a/ViewController.xctemplate/ViewController-Instantiatable Injectable Interactable/___FILEBASENAME___ViewController.swift +++ /dev/null @@ -1 +0,0 @@ -../ViewController+Injectable+Interactable.swift \ No newline at end of file