https://github.com/protomorph/appcheck
ApplicationCache updater
https://github.com/protomorph/appcheck
Last synced: over 1 year ago
JSON representation
ApplicationCache updater
- Host: GitHub
- URL: https://github.com/protomorph/appcheck
- Owner: protomorph
- License: gpl-2.0
- Created: 2014-11-22T21:53:28.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2016-04-06T04:09:54.000Z (about 10 years ago)
- Last Synced: 2025-01-27T07:13:38.398Z (over 1 year ago)
- Language: JavaScript
- Size: 9.77 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
AppCheck
======================
ApplicationCache updater based on the idea found at [html5rocks][2]
#### Usage
To enable the application cache for an app, include the manifest attribute on the document's html tag.
``````
...
``````
A manifest file must be served with the mime-type text/cache-manifest.
You may need to add a custom file type to your web server or .htaccess configuration.
``````
AddType text/cache-manifest .appcache
``````
The manifest is a separate file you link to via the manifest attribute on the html element.
``````
CACHE MANIFEST
# 2010-06-18:v2
# Explicitly cached 'master entries'.
CACHE:
/favicon.ico
index.html
stylesheet.css
images/logo.png
scripts/main.js
# Resources that require the user to be online.
NETWORK:
*
# static.html will be served if main.py is inaccessible
# offline.jpg will be served in place of all images in images/large/
# offline.html will be served in place of all other .html files
FALLBACK:
/main.py /static.html
images/large/ images/offline.jpg
``````
Then include the appcheck javascript in your document to update the ApplicationCache.
``````
``````
For more information about ApplicationCache visit: [html5rocks][2]
#### License
[GNU General Public License v2][3]
© 2014 - [ProtoMorph][1]
[1]: http://protomorph.cf/
[2]: http://www.html5rocks.com/en/tutorials/appcache/beginner/
[3]: http://opensource.org/licenses/GPL-2.0