executablebooks / markdown-it-docutils

A markdown-it plugin for implementing docutils style roles/directives.
https://executablebooks.github.io/markdown-it-docutils/
MIT License
12 stars 9 forks source link

How best to handle SASS compilation? #3

Open chrisjsewell opened 3 years ago

chrisjsewell commented 3 years ago

So I was trying to get this to work with rollup, and there are a number of plugins to do it. But I couldn't work out how to simply compile it to its own folder:

Currently using directly sass --style=compressed --source-map --embed-sources src/style/index.sass dist/css/style.min.css this works generally fine as a standalone compiler, however: it would be noce to integrate it with rollup, and also add postcss transforms, in particular in https://github.com/postcss/autoprefixer.

Note in https://github.com/executablebooks/markdown-it-docutils/commit/90a6e9466a9a5b7534f2a41ea4046f6cdd845052, I added autoprefixer to the css compile, and it seems to work. I was a bit worried it would mess up the source map, but that also appears to be properly handled 😄