stencil icon indicating copy to clipboard operation
stencil copied to clipboard

bug: SCSS doesn't rebuild when path is outside stencil directory

Open James-Wilkinson-git opened this issue 10 months ago • 11 comments

Prerequisites

Stencil Version

4.13

Current Behavior

When you make a change to an SCSS file that lives outside of the stencil directory the changes are not picked up and re-rendered. This is an issue when using stencil in a mono-repo environment with shared styles.

Expected Behavior

Watcher should listen for changes and recompile scss when the files provided are changed.

System Info

No response

Steps to Reproduce

Edit the scss and see it doesn't update from red to blue for example. https://github.com/James-Wilkinson-git/stencil-bug

Code Reproduction URL

https://github.com/James-Wilkinson-git/stencil-bug

Additional Information

Relates too https://github.com/ionic-team/stencil/issues/2635

James-Wilkinson-git avatar Mar 28 '24 12:03 James-Wilkinson-git

@James-Wilkinson-git thanks for raising the issue.

I am not really able to reproduce this. I checked out the code, installed the dependencies and ran npm start. I am able to make changes to the .scss file, see:

repro

Anything I am doing wrong here?

christian-bromann avatar Apr 01 '24 08:04 christian-bromann

I blew away node_modules and package-lock did a fresh npm install and still the same issue it doesn't run. Also using VSCode.

My co-worker on a mac also sees the same issue, what could be causing it?

James-Wilkinson-git avatar Apr 01 '24 11:04 James-Wilkinson-git

Can you provide a step by step explanation how this can be reproduced on your machine using the reproducible example?

christian-bromann avatar Apr 01 '24 13:04 christian-bromann

I did… fresh install the repo and I have the problem. But you did It and dont. So something has to be up with the watcher source code compiling on install maybe? Node versions? Windows versions? I don’t know how that stuff works to help troubleshoot better

James-Wilkinson-git avatar Apr 02 '24 01:04 James-Wilkinson-git

Windows versions?

Are you on Windows?

christian-bromann avatar Apr 02 '24 08:04 christian-bromann

npm 8.19.4 node 20.10.0 Windows 10 Enterprise x64

James-Wilkinson-git avatar Apr 02 '24 13:04 James-Wilkinson-git

Thanks for this information. We were able to validate this defect on Windows. We will ingest this into our backlog and will prioritize it accordingly.

christian-bromann avatar Apr 02 '24 17:04 christian-bromann

Oh that's great news!

tfrijsewijk avatar Apr 03 '24 19:04 tfrijsewijk

This may be related, I might need to use powershell instead of git-bash inside vscode to get it to work until windows fixes https://github.com/microsoft/WSL/issues/4739

James-Wilkinson-git avatar Apr 18 '24 19:04 James-Wilkinson-git

I might need to use powershell

Can you confirm that the expected behavior works using Powershell?

christian-bromann avatar Aug 20 '24 22:08 christian-bromann

For me it doesn't matter which terminal I use (PowerShell, pwsh, git bash or Mac's Terminal). Nested sass files are not change-detected.

tfrijsewijk avatar Sep 18 '24 13:09 tfrijsewijk