Skip to content

Latest commit

 

History

History
17 lines (13 loc) · 492 Bytes

README.md

File metadata and controls

17 lines (13 loc) · 492 Bytes

About

AMD-cache is a plugin for AMD loaders. It will store loaded modules in localStorage, if available. For subsequent page loads that module will be loaded from localStorage and not trigger a network request.

Usage

Download the chache.js file. In your code, prefix the module that you require() with cache! like this:

require(['cache!myModule'], function(myModule){
  myModule.doSomething();
});