UNPKG

@ulu/sassdoc-to-markdown

Version:

A flexible SCSS documentation tool that generates clean, customizable Markdown from your Sass stylesheets. It leverages SassDoc for data extraction and offers various configuration options to tailor the output to your specific needs

24 lines (22 loc) 681 B
import stripIndent from 'strip-indent' /** * Provides compiler code (sass source code to include when compiling examples) * - Use to import modules, etc * - Use as a file level comment to incude in all * - Can use multiple (ie. file level, item/example level) */ export default function compiler(options, info) { return function group () { return { name: 'compiler', parse(text) { const code = text.split('\n'); // Code to include in compiled is below main annotation // in future the first line could hold arguments, etc code.shift(); return stripIndent(code.join("\n")); }, multiple: true, } } }