2015-12-22 20:41:40 +00:00
|
|
|
es5-ff-spa-loader
|
2015-12-23 00:16:54 +00:00
|
|
|
=========
|
|
|
|
|
|
|
|
A javascript library providing server defined loading of resouces for a single page application.
|
|
|
|
|
|
|
|
## Installation
|
|
|
|
|
|
|
|
Use the es5-ff-spa-loader.js in header as script resource or inline in body.
|
|
|
|
|
|
|
|
## Usage
|
|
|
|
|
|
|
|
On index.html
|
|
|
|
|
2016-01-14 21:42:13 +00:00
|
|
|
FFSpaLoader.start(...);
|
2015-12-23 00:16:54 +00:00
|
|
|
|
|
|
|
## Options
|
|
|
|
|
|
|
|
* url = The url to fetch resources list from.
|
|
|
|
* debug = Enable console debug output.
|
|
|
|
* cachePrefix = The cache key prefix. (default: 'sync-')
|
|
|
|
* cacheGetFn = example; 'function(key) {return localStorage.getItem(key);}'
|
|
|
|
* cacheSetFn = example; 'function(key,value) {localStorage.setItem(key,value);}'
|
|
|
|
* cacheDelFn = example; 'function(key) {return localStorage.removeItem(key);}'
|
|
|
|
|
|
|
|
## Example Application
|
|
|
|
|
|
|
|
There is a fully working express example application in the example folder.
|
|
|
|
todo
|
|
|
|
|
|
|
|
## Contributing
|
|
|
|
|
|
|
|
In lieu of a formal styleguide, take care to maintain the existing coding style.
|
|
|
|
Add unit tests for any new or changed functionality. Lint and test your code.
|
|
|
|
|
|
|
|
## Release History
|
|
|
|
|
|
|
|
### 0.1.x
|
|
|
|
* Initial release
|