Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Enable Source Maps for SCSS to CSS compilation #216

Open
fabinol opened this issue Mar 16, 2017 · 3 comments
Open

Enable Source Maps for SCSS to CSS compilation #216

fabinol opened this issue Mar 16, 2017 · 3 comments

Comments

@fabinol
Copy link
Contributor

fabinol commented Mar 16, 2017

Note to @markfinger poke around Google, there is something out there that solves the problem.

@fabinol
Copy link
Contributor Author

fabinol commented Mar 16, 2017

Integrate build script from other projects + update package json.

@fabinol fabinol changed the title Enable Source Mapd for SCSS to CSS compilation Enable Source Maps for SCSS to CSS compilation Mar 16, 2017
@markfinger
Copy link
Member

Have been poking around and investigating both the django-compressor and django-pipeline ecosystems. Unfortunately, both were architected at a time before source maps, so support requires a lot of hacks and poor outcomes due to implementation details.

An alternative solution - and possibly the optimal one - is to re-roll the necessary bits + pieces to integrate source maps. My instinct says to try and integrate with bits of compressor, but there are too many issues there, so I think this will be a path ending with a lot of code. In mildly exciting news, I've built a few asset pipelines + built tools in my time, so I could recycle a bunch of concepts and code snippets.

Not sure what the correct path to take is, as both will require a certain amount of time. Hacking around compressor/pipeline is probably the fastest path, but is also the riskiest as there are likely to be hidden implementation details that prevent achieving a satisfactory outcome. Rolling our own is likely to take longer, but is the safer path.

Will muse for a while...

@markfinger
Copy link
Member

A third option I forgot, is to use an external build process built on webpack or gulp. This would be probably the sanest solution, but there are always a bunch of integration woes as the build process won't be able to introspect the python process easily. Unless you were to wrap the build process in a management command that populated env vars that the config read in.

Either way, will muse for a while...

@markfinger markfinger removed their assignment Jul 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants