Rails plugin to help manage your CSS and Javascript
Shoebox lets you maintain your styles and scripts as first-class citizens while giving you controller-level granularity over their use.
Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!
Shoebox lets you maintain your styles and scripts as first-class citizens while giving you controller-level granularity over their use.
Comments
This looks somewhat like my Needy Controllers plugin, but I abandoned using it in production apps because it isn’t able to cache everything together into single big minified files. Is shoebox able to work with things like asset packager and general Rails style merging?
Shoebox merges all of the files together for a particular controller. The helper generates a url like /shoebox/styles/users which when requested returns a single (optionally minified) stylesheet.
Hey David,
But I looked though the code (just glanced) and doesn’t look like it has any caching at this point. Not sure how hard it would be to code it in. I really like the idea of getting away for public folder usage and going into a sane management system for my CSS and JS. But the performance lose from no caching I certainly can’t justify. Maybe I’ll see what I can code up in a couple days.
You’re correct, there is currently no caching.
Caching and SASS support are on my plate for next features.
SASS support is now in.
And now caching support.
Active, iterative development in action - cool!
Post a comment