Skip to content
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

Make the sourcemap available #6

Closed
weaverryan opened this issue Aug 18, 2023 · 3 comments
Closed

Make the sourcemap available #6

weaverryan opened this issue Aug 18, 2023 · 3 comments

Comments

@weaverryan
Copy link
Contributor

When the package builds, a .map file is output. But, we're not currently making it available.

Another option is to pass --embed-source-map and embed it directly in the CSS file (in dev mode only).

weaverryan added a commit that referenced this issue Aug 21, 2023
This PR was squashed before being merged into the main branch.

Discussion
----------

Adding embedded sourcemaps

Simple solution to #6 - sourcemaps are included in the final `.css` file in debug mode.

Commits
-------

f75d41d Adding embedded sourcemaps
@schugs4
Copy link
Contributor

schugs4 commented Sep 13, 2023

Is this a symptom where the bundle builds a compiled correctly css file in var/sass/* but asset-mapper is still just serving a temp file that is an exact replica of the original scss? That is what i am getting, not sure what i am missing.

As a validation that the SASS build side is working properly, i added an exclude on the asset-mapper config.yaml to ignore scss files, then added an path to var/sass/. and changed the link in the template to app.output.css and it does work correctly.

So its something with how the bundle is supposed to override the default scss rendering.

@weaverryan
Copy link
Contributor Author

Hey!

First, I just added some details about excluding paths - 8153fd6 - be careful you're not excluding your actual app.scss file.

Anyway, I bet this is the problem: #14

weaverryan added a commit that referenced this issue Sep 13, 2023
This PR was merged into the main branch.

Discussion
----------

Using realpath everywhere for consistent comparison

#6 (comment)

Commits
-------

78955f5 using realpath everywhere for consistent comparison
@schugs4
Copy link
Contributor

schugs4 commented Sep 14, 2023

Confirming that 2.2 resolved the issue i was having. Thanks!

Related to your note, i have two questions,
1.) Does the bundle always only look at assets/styles/app.scss? When i tried moving it to assets/app.scss app threw an error that it couldn't find assets/styles/app.scss?
2.) Nevermind on this, just saw you did '*.scss' to exclude any scss that starts with an '' -The reason i wanted to move it was to add the assets/styles to the exclude list and just have one scss file at the root, in the comments you added in 8153fd6 i don't understand how that wouldn't exclude assets/styles/app,scss. Is there a recommended exclude statement that excludes others but NOT app.scss?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants