Skip to content

Commit

Permalink
added scrollStuff to Docs
Browse files Browse the repository at this point in the history
  • Loading branch information
mmcmoritz committed Jun 21, 2019
1 parent ee2e60f commit e5f487a
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ Scrollimate focuses on features and functions related to scrolling, animations (
- [springyElement](#springyelement)
- [Basic Setup](#springyelementBasic)
- [Advanced](#springyelementAdvanced)
- [scrollStuff](#scrollstuff)
- [Basic Setup](#scrollstuffbasic)
- [Advanced](#scrollstuffadvanced)

## <a name="setup"></a>Setup and Usage:

Expand Down Expand Up @@ -456,5 +459,30 @@ Takes one argument, the amount of pixels an element can travel (20px by default)

*note:* You can currently _not_ call this advanced setup via this init() method.

---
---

# <a name="scrollstuff"></a>scrollstuff
Simple jQuery _“stuff is scrolled into view so let's add a class”_ plugin

## Usage:
### <a name="scrollstuffbasic"></a>Basic
scrollstuff Extends the jQuery Object with a new method, so the easiest usage is like this:

$('your-selector-here').scrollstuff({});

### <a name="scrollstuffadvanced"></a>Advanced
You van also run scrollstuff with arguments

$('your-selector-here').scrollstuff({
classname: 'custom-class-name',
delay: 700,
repeat: true
});

The scrollstuff object current accepts the following arguments in object notation:
* classname _(string)_ — name of the class to attach to object. `'this--nowinview'` by default.
* delay _int_ — delay until class is added, in milliseconds
* repeat _boolean_ whether or not the animation repeats when it's out and in of view again

#### That's it! Have fun and enjoy the ride and all that good stuff!

0 comments on commit e5f487a

Please sign in to comment.