diff --git a/Statico/ViewController.swift b/Statico/ViewController.swift index 7608893..e7e64f3 100644 --- a/Statico/ViewController.swift +++ b/Statico/ViewController.swift @@ -13,6 +13,7 @@ class ViewController: UIViewController { @IBOutlet weak var tableView: UITableView! + // How to use Static with a custom view controller let dataSource = DataSource() override func viewDidLoad() { @@ -25,8 +26,24 @@ class ViewController: UIViewController { rows: [ Row(text: "foo"), Row(text: "bar"), + // How to add a selection callback Row(text: "tap me", selection: { self.showAlert() }) ] + ), + // How to add more sections (super easy) + Section( + header: Section.Extremity.Title("fancy"), + rows: [ + Row(text: "text", + detailText: "detail text", + selection: nil, + image: nil, + accessory: Row.Accessory.DisclosureIndicator), + Row(text: "bar"), + ], + footer: Section.Extremity.Title("This is the footer"), + indexTitle: "Index title", + UUID: "UUID" ) ] }