Allow easier hooks to provide simple, custom stylesheet/javascript requires
Created by: coneybeare
Problem
I made a custom Font-Awesome field that displays a stored icon name string ("fa-facebook") as its rendered icon rather than its name. After getting the appropriate gem, I need to add one line into the application.css
file.
Generating the entire administrate:assets:stylesheets
stack so I can plug this one value in seems a bit sledgehammerish.
Ideas
Not sure if any/all of these are technically possible.
- Somehow add a hook into the stylesheet and javascript manifest files that can
require
into the main app by looking in a special folder or file. - Have main app define the root manifest files for the engine, with only a
require administrate.scss
etc... entry in it. This would allow additional requires before or after the gem scss. - Setup some sort of config variable that could take some paths to require within
administrate.scss
Or maybe I am just dense and am not seeing the easy way to do this without freezing the entire stylesheet stack into my main app. Ideas?