Snooze Squad is on npm! You can find it under the name [`snooze-squad`](https://www.npmjs.com/package/snooze-squad), and install it with `npm install snooze-squad`.
Using Snooze Squad is really easy. Here's a simple example:
```javascript
window.snoozeSquad = new SnoozeSquad({});
```
The first parameter in the above is the _options object_. You can specify a number of options that are listed below if you want to. Note that the options object is currently _required_, and SnoozeSquad won't work without it.
Once you've got that set up, change the name of the `src` attribute of all images that you want to be lazy loaded to `data-src`. The contents of `data-src` will be copied over to the `src` attribute when the image is woken up. Example:
Snooze Squad should also properly detect which images are currently in the viewport, and load them automatically.
You can also set the `src` attribute of your lazily-loaded images to a placeholder or other loading image / animation - Snooze Squad will overwrite this with the actual address of the image when the image is lazily loaded.
Note that if you submit pull requests, it would be helpful if you _didn't_ minify the file yourself if there's alreayd a pull request waiting. That just gets messy.
### Setup
If you're on linux, just run `make setup` in the current directory. If not (or you're on a machine without `sudo` - how odd!), just run `npm install uglify-js-harmony --global` instead.