Skip to content

Commit db02ef1

Browse files
committed
Tweak readme
1 parent d3e8aa9 commit db02ef1

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

readme.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -98,21 +98,21 @@ options object as the second.
9898
`document.body`)
9999
* Doesn't automatically fire, so you need to bind it to some other user
100100
interaction. For example:
101-
102-
$('button.scrollsomething').on('click', function() {
103-
$.smoothScroll({
104-
scrollElement: $('div.scrollme'),
105-
scrollTarget: '#findme'
106-
});
107-
return false;
108-
});
109-
101+
```js
102+
$('button.scrollsomething').on('click', function() {
103+
$.smoothScroll({
104+
scrollElement: $('div.scrollme'),
105+
scrollTarget: '#findme'
106+
});
107+
return false;
108+
});
109+
```
110110
* The `$.smoothScroll` method can take one or two arguments.
111111
* If the first argument is a number or a "relative string," the document is scrolled to that
112112
position. If it's an options object, those options determine how the
113113
document (or other element) will be scrolled.
114114
* If a number or "relative string" is provided as the second argument, it will override whatever may have been set for the `scrollTarget` option.
115-
* The relative string syntax, introduced in version 2.1, looks like `+=100px` or `-=50px` (see below for an example).
115+
* The relative string syntax, introduced in version 2.1, looks like `"+=100px"` or `"-=50px"` (see below for an example).
116116

117117
#### Additional Option
118118
The following option, in addition to those listed for `$.fn.smoothScroll` above, is available

0 commit comments

Comments
 (0)