Skip to content

Commit 7a10bea

Browse files
committed
Updated to version 1.2
1 parent 4798d14 commit 7a10bea

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ Basic code to make it work:
3030

3131

3232
If you need to sync your model with ParagraphTextStorage content, set the paragraphDelegate to adopt the ParagraphTextStorageDelegate protocol.
33-
It's just two methods:
33+
It's simple:
3434

3535
var presentedParagraphs: [AttributedRepresentable] {
3636
yourModel.paragraphs
@@ -58,9 +58,7 @@ Finally, set the paragraphDelegate property of the ParagraphTextStorage instance
5858
That's all you need to implement to make things work.
5959

6060
### Important changes in version 1.2:
61-
This version introduces the AttributedRepresentable protocol that defines the attributed string representation of any model. In our case we use this protocol to create even stronger syncronization between a delegate and ParagraphTextStorage.
62-
63-
Updated delegate protocol with new requrements of the model which now should adopt AttributedRepresentable protocol allows ParagraphTextKit to load the initial state of your model into its underlying text storage property.
61+
Updated delegate protocol with new requrements of the model which now should be able to present its paragraphs as array of NSAttributedStrings. That allows ParagraphTextKit to load the initial state of your model into its underlying text storage property.
6462

6563
In previous versions ParagraphTextKit was able to do its job only if your initial text model was empty. If you've already had some paragraphs in your model then you'd need to set ParagraphTextStorage content by yourself right after the initialization. Now ParagraphTextKit takes that onto itself completely.
6664

0 commit comments

Comments
 (0)