diff --git a/README.md b/README.md
index 23d35e5..d23abe9 100644
--- a/README.md
+++ b/README.md
@@ -7,7 +7,7 @@
-Tablet is a super lightweight yet powerful generic library that handles a complexity of UITableView's datasource and delegate methods in a Swift environment. Tablet's goal is to provide an easiest way to create complex table views. With Tablet you don't have to write a messy code of switch or if statements when you deal with bunch of different cells in different sections.
+Tablet is a super lightweight yet powerful generic library that handles a complexity of UITableView's datasource and delegate methods in a Swift environment. Tablet's goal is to provide an easiest way to create complex table views. With Tablet you don't have to write a messy code of `switch` or `if` statements when you deal with bunch of different cells in different sections.
That's almost all you need in your controller to build a bunch of cells in a section:
```swift
@@ -89,7 +89,7 @@ Once you've implemented the protocol, simply use the `TableConfigurableRowBuilde
```swift
import Tablet
-let rowBuilder = TableConfigurableRowBuilder()
+let rowBuilder = TableConfigurableRowBuilder(estimatedRowHeight: 42)
rowBuilder.appendItems(users)
director = TableDirector(tableView: tableView)
@@ -159,17 +159,18 @@ extension TableDirector {
public func tableView(tableView: UITableView, didEndDisplayingCell cell: UITableViewCell, forRowAtIndexPath indexPath: NSIndexPath) {
- performAction(.custom(kTableDirectordidEndDisplayingCell), cell: cell, indexPath: indexPath)
+ performAction(.custom(kTableDirectorDidEndDisplayingCell), cell: cell, indexPath: indexPath)
}
}
```
Catch your action with row builder:
```swift
-let rowBuilder = TableConfigurableRowBuilder(items: users)
- .action(kTableDirectordidEndDisplayingCell) { data in
+let rowBuilder = TableConfigurableRowBuilder(items: users, estimatedRowHeight: 42)
+ .action(kTableDirectorDidEndDisplayingCell) { data in
}
```
+You could also perform an action that returns a value.
## License
diff --git a/Tablet.podspec b/Tablet.podspec
index 5d4d01f..de7a9f9 100644
--- a/Tablet.podspec
+++ b/Tablet.podspec
@@ -3,7 +3,7 @@ Pod::Spec.new do |s|
s.version = '0.1.0'
s.homepage = 'https://github.com/maxsokolov/tablet'
- s.summary = 'Tablet is a super lightweight yet powerful Swift library that handles a complexity of UITableView's datasource and delegate.'
+ s.summary = 'Powerful type-safe tool for UITableView. Swift 2.0 is required.'
s.author = { 'Max Sokolov' => 'i@maxsokolov.net' }
s.license = { :type => 'MIT', :file => 'LICENSE' }
diff --git a/TabletDemo/TabletDemo.xcodeproj/project.xcworkspace/xcuserdata/maxsokolov.xcuserdatad/UserInterfaceState.xcuserstate b/TabletDemo/TabletDemo.xcodeproj/project.xcworkspace/xcuserdata/maxsokolov.xcuserdatad/UserInterfaceState.xcuserstate
index fe7b4a0..37a26d5 100644
Binary files a/TabletDemo/TabletDemo.xcodeproj/project.xcworkspace/xcuserdata/maxsokolov.xcuserdatad/UserInterfaceState.xcuserstate and b/TabletDemo/TabletDemo.xcodeproj/project.xcworkspace/xcuserdata/maxsokolov.xcuserdatad/UserInterfaceState.xcuserstate differ
diff --git a/TabletDemo/TabletDemo/ViewController.swift b/TabletDemo/TabletDemo/ViewController.swift
index 240941c..ed353d5 100644
--- a/TabletDemo/TabletDemo/ViewController.swift
+++ b/TabletDemo/TabletDemo/ViewController.swift
@@ -50,7 +50,7 @@ class ViewController: UIViewController {
}
.action(.configure) { (data) -> Void in
- data.cell!.contentLabel.text = "With iOS 8, Apple has internalized much of the work that previously had to be implemented by you prior to iOS 8. In order to allow the self-sizing cell mechanism to work, you must first set the rowHeight property on the table view to the constant UITableViewAutomaticDimension. Then, you simply need to enable row height estimation by setting the table view's estimatedRowHeight property to a nonzero value, for example"
+ data.cell!.contentLabel.text = "Tablet is a super lightweight yet powerful generic library that handles a complexity of UITableView's datasource and delegate methods in a Swift environment. Tablet's goal is to provide an easiest way to create complex table views. With Tablet you don't have to write a messy code of switch or if statements when you deal with bunch of different cells in different sections."
}
let sectionBuilder = TableSectionBuilder(headerTitle: "Tablet", footerTitle: "Deal with table view like a boss.", rowBuilders: [rowBuilder, configurableRowBuilder])