Build output includes .scss files from src directory #828
Replies: 3 comments
-
Thanks for raising. I understand and agree this isn’t expected behavior from the standpoint of your project. From Snowpack’s end, this is technically “expected behavior” until we release an official Sass plugin (“expected behavior” in quotes because it’s not ideal, but it is consistent with our plan of having plugins do more and Snowpack do less custom behavior management). Reason is: our Sass recipe uses the run script, which currently doesn’t have a way to clean up file extensions. Further, you can’t We currently have a Sass community plugin which should prevent this behavior, but I haven’t tested this myself. Just a note: it uses
That sounds about right. Even though we overhauled the build pipeline in |
Beta Was this translation helpful? Give feedback.
-
Actually, that is what I want. I just want to exclude them altogether. I couldn't find a relevant config option to do this in the docs. How would I exclude certain file extensions from the build process? Edit: Oh - the top level Adding Thanks for pointing out the sass plugin, I may look into that later on. For now, we do the sass build separately from snowpack so excluding altogether is what I want. |
Beta Was this translation helpful? Give feedback.
-
Oh yup! That’s the one. 🤔 I had originally been thinking that excluding Sass altogether would break HMR in the dev server, but as long as Sass is watching & outputting CSS, I guess it wouldn’t matter! Perhaps we should recommend excluding Sass for now in the docs. But I’d still like to have an official Sass plugin someday so that people don’t have to fuss with the run-script-plugin + config options. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
As I reported here #782 (comment) builds (including
--watch
) output.scss
files that are in mysrc/
todist/
. I expectdist/
to only have the.js
files for my build (I don't have apublic/
dir to copy for my build). I'm using2.8.0-pre.4
.2.7.5
did not have this behaviour, I think it started with2.7.7
.Beta Was this translation helpful? Give feedback.
All reactions