0.0.2 • Published 9 years ago

sassdoc-loader v0.0.2

Weekly downloads
1
License
ISC
Repository
-
Last release
9 years ago

sassdoc-loader

npm install sassdoc-loader --save-dev

Uses SassDoc to load your docs as a javascript object. Useful for rolling your own sassdoc theme.

Usage

var myDocs = require("!!sassdoc-loader!./sassfile.scss");

Note: The double !! before the loader makes sure to disable all loaders specified in the config file. See: webpack loader order

Caveats

Sassdoc and Webpack traverse files in different ways; sassdoc uses a globbing mechanism while webpack only uses files that are explicitly required from the entry point. Because of this we use sass-import-resolve to find all the files inside the required sass file. If you don't have one standard entry point to your sass you may need to create a separate docs.scss file that lists all individual files.

Any better solutions to this problem would be much appreciated.