Skip to content

Instantly share code, notes, and snippets.

@vidhill
Created March 1, 2016 14:00
Show Gist options
  • Save vidhill/c1a062d3f26c8e762419 to your computer and use it in GitHub Desktop.
Save vidhill/c1a062d3f26c8e762419 to your computer and use it in GitHub Desktop.
Quick and dirty example of workaround to display css class body from SassDoc
//
var passClassBody = function(myContext){
myContext.data.filter(function(item){
if( item.context.type === 'css'){
item.context.code = '\n' + item.context.value + '\n'; // copy value over to code, so that it is outputted as regular sass is
}
return item;
});
return myContext
}
/* Excluded source */
module.exports = function (dest, ctx) {
passClassBody(ctx);
/**
* continues...
*
*/
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment