-
Notifications
You must be signed in to change notification settings - Fork 54
Add more cli opts and source map config args #279
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add more cli opts and source map config args #279
Conversation
ec00f07
to
560ebbb
Compare
whoa this is great, there's a lot for me to read through so it might take me a bit to get to it all but this is incredible! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
a few little things! overall looks good
560ebbb
to
734d4ab
Compare
I've incorporated the feedback in the latest commit. Let me know if I missed something. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for this awesome change! I'll try it out and then hopefully get a release soon |
so sorry, I totally forgot about this -- looking at getting #280 in and making a release |
this has been released in 0.17.0 🎉 -- thanks again! |
I had the need to be able to emit source maps using libsass-python that contain
sourcesContent
. When I set out to make a PR to add this functionality I realized that there are quite a few libsass options not exposed through the API, and also that the cli script does not allow setting all of the options that are already exposed. With these PR, the library and cli script are brought into feature parity with other libsass bindings, such as node-sass.Newly added kwargs include:
source_map_contents
: EmitssourcesContent
property in source map (fixes Support embedding sources' contents #268)source_map_embed
: Embeds sourcemap as a data uri insourceMappingURL
commentomit_source_map_url
: Omits the source map comment from the css output filesource_map_root
: Sets thesourceRoot
property in a source mapAll of these are exposed via the cli using the existing naming conventions, i.e.
source_map_contents
can be enabled with--sourcemap-contents
.Newly added cli flags that map onto already exposed libsass options:
-i
/--indented-syntax
: enables sass (not scss) parsing--sourcemap-file
: Allows overriding ofsource_map_filename
via the cli