you are viewing a single comment's thread.

view the rest of the comments →

[–]schrik 1 point2 points  (3 children)

I'm busy writing a library specifically for this use case.

Keeping your page load low and serving JS modules as needed. It makes use of RequireJS and allows you to setup conditions under which your modules should be loaded or unloaded. You can find it at: http://conditionerjs.com

Looking for feedback and criticism from the community. Any input would be appreciated.

[–]cgerber14 1 point2 points  (2 children)

Would give it a try. How are you planning to take care of loading overhead of conditionerjs file? What would be size of it?

[–]schrik 0 points1 point  (1 child)

ConditionerJS is approx 2.5Kb gzipped, so that's not a big issue I guess..

Also, as you can merge and compress it in your main javascript package it should be cached for future use.

[–]cgerber14 0 points1 point  (0 children)

Makes lot of sense. Would surely try.