Skip to content

Commit 4d0c27d

Browse files
committed
Add plunkr to Readme
1 parent ee01566 commit 4d0c27d

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

README.md

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,16 @@ USAGE
3030

3131
It's a filter, you use it in your html like this:
3232

33-
```{{text|diff:otherText}}```
33+
```<div ng-bind-html="oldText|diff:newText"></div>```
3434

35-
This will show the diff between ```text``` and ```otherText```
35+
This will show the diff between ```oldText``` and ```newText```
36+
37+
Note that the filter returns html with <ins> and <del> tags, so in order to
38+
display it you have to use ng-bind-html.
39+
40+
Here's a demo, that's worth more than a thousand words:
41+
42+
[http://plnkr.co/edit/nfhA5g?p=preview](http://plnkr.co/edit/nfhA5g?p=preview)
3643

3744

3845
DEVELOPMENT

0 commit comments

Comments
 (0)