Skip to content


idea: Caching code resulting from a feature driven bootstrapping process #75

davidmarkclements opened this Issue · 1 comment

2 participants


Just thought of a pretty cool use case for basket.js:

Caching code resulting from a feature driven bootstrapping process

So what I mean is, an interface similar to the likes of Modernizr.load (or even just a duck punch to the same)
that looks for certain features and dynamically loads any relevant code to polyfill or provide alternative functionality. Where basket.js would come in, is once that code has been assembled for the browser and
committed to localStorage - all that has to happen on the next load is a check for the code base in localStorage
if it's there no feature detection or loading of multiple external scripts has to happen.

At the moment, this would benefit most in browsers that don't actually implement localStorage. So basket.js (or a derivative) could become a façade for script caching in general, falling back to other (ugly) persistant storage methods for the likes of ie etc.

Depending on project direction, this could perhaps be outside the scope, but I thought I'd share it before I forgot about anyway.


Good idea, but of the scope for this project. Do let us know if you pursue it though ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.