Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Make it possible to expose application level variables as separate files... #15

Closed
wants to merge 3 commits into
from

Conversation

Projects
None yet
1 participant
Contributor

ForbesLindesay commented Apr 3, 2012

... at URLs which look like /bundle/:name.js where the default exposed items are at /bundle/javascript.js

To use this feature, just call app.exposeBundles(); It can be passed a function to call before (useful if you want to check a cache first) and a function to call after (useful for minification and saving to the cache).

@ForbesLindesay ForbesLindesay Make it possible to expose application level variables as separate fi…
…les at URLs which look like /bundle/:name.js where the default exposed items are at /bundle/javascript.js


TO use this feature, just call app.exposeBundles();  It can be passed a function to call before (useful if you want to check a cache first) and a function to call after (useful for minification and saving to the cache).
5eb06b0
Contributor

ForbesLindesay commented Apr 3, 2012

The reason for doing this, in case that's not clear, is that for websites where many requests are made, you only want to load the stuff which is different for each request, not the entirety of all JavaScript the site serves. It also offers useful interfaces for people who want to compress/minify/cache their exposed values.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment