This commit is contained in:
Igor Kislyuk 2017-11-14 16:13:05 +03:00
parent 357dca82e3
commit a5f8a5813a
5 changed files with 15 additions and 27 deletions

View File

@ -1,15 +0,0 @@
# Template information section
name: "touchin-cell"
summary: "Swift UITableViewCell for TableKit using in Touch Instinct"
author: "Igor Kislyuk"
version: "0.1.0"
license: "MIT"
# The declarations for code files
code_files:
# cell
- {name: UITableViewCell.swift, path: Cell/cell.swift.liquid, custom_name: "{{module_info.name}}.swift"}
- {name: CellViewModel.swift, path: Cell/cellViewModel.swift.liquid, custom_name: "{{module_info.name}}ViewModel.swift"}
- {name: UITableViewCell.xib, path: Cell/view.xib.liquid, custom_name: "{{module_info.name}}.xib"}

View File

@ -8,22 +8,10 @@ final class {{ module_info.name }}: UITableViewCell, ConfigurableCell {
fileprivate var disposeBag = DisposeBag()
override func awakeFromNib() {
super.awakeFromNib()
clear()
}
override func prepareForReuse() {
super.prepareForReuse()
clear()
}
private func clear() {
disposeBag = DisposeBag()
// clear other elements
}
func configure(with viewModel: {{ module_info.name }}ViewModel) {

View File

@ -0,0 +1,15 @@
# Template information section
name: "touchin-tablecell"
summary: "Swift UITableViewCell for TableKit using in Touch Instinct"
author: "Igor Kislyuk"
version: "0.1.0"
license: "MIT"
# The declarations for code files
code_files:
# cell
- {name: UITableViewCell.swift, path: TableCell/cell.swift.liquid, custom_name: "{{module_info.name}}.swift"}
- {name: CellViewModel.swift, path: TableCell/cellViewModel.swift.liquid, custom_name: "{{module_info.name}}ViewModel.swift"}
- {name: UITableViewCell.xib, path: TableCell/view.xib.liquid, custom_name: "{{module_info.name}}.xib"}