Skip to content

Commit 4f20393

Browse files
committed
updated readme
1 parent ae4f373 commit 4f20393

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
## Usage
2+
jquery.typer.js can be used one of two ways:
3+
4+
### Type once with typeTo()
5+
6+
If you just want to use the effect once, use `typeTo()`. It can be used as follows:
7+
8+
$('h3').typeTo("New Text");
9+
10+
This will do a one-time transition.
11+
12+
### Type indefinitely with typer()
13+
14+
Now let's say you want to loop over a set of strings for the typing effect. Easy!
15+
16+
$('[data-typer-targets]').typer();
17+
18+
19+
That code will start the effect on all elements with the `data-typer-targets` attribute.
20+
21+
You obviously need to supply it with some source data. The `data-typer-targets` attribute can be either a comma-separated string or a piece of JSON.

0 commit comments

Comments
 (0)