Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/hojberg/ignite

JavaScript init loader
https://github.com/hojberg/ignite

Last synced: about 1 month ago
JSON representation

JavaScript init loader

Awesome Lists containing this project

README

        

* add init functions on with a condition
ignite.add({condition: true, func: function () { /* ... */ }});
* can also just be the boolean as the first argument
ignite.add(true, function () { /* ... */ });

* always run the init function
ignite.add(function () { /* ... */ });

* run the init function if #myid exists in the dom
* you can pass a selector engine to the self executing function
* that ignite is wrapped in to use jquery or similar
ignite.add("#myid", function () { /* ... */ });

* run with:
$(document).ready(ignite.spark);