Skip to content

Unlisted CSS using preprocessor does not build css file #1580

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

Open
5 tasks done
PortalCube opened this issue Apr 16, 2025 · 1 comment · May be fixed by #1590
Open
5 tasks done

Unlisted CSS using preprocessor does not build css file #1580

PortalCube opened this issue Apr 16, 2025 · 1 comment · May be fixed by #1590
Labels
pending-triage Someone (usually a maintainer) needs to look into this to see if it's a bug

Comments

@PortalCube
Copy link

PortalCube commented Apr 16, 2025

Describe the bug

I encountered a situation where I needed to add a stylesheet dynamically, so I tried using unlisted CSS. I created a .scss as unlisted CSS, but the scss file was not generated as a CSS output.

When adding regular .css as unlisted CSS, it works without any issues, so it seems like there's something wrong related to sass.

Reproduction

unlisted-css-bug.zip

Steps to reproduce

  1. npx wxt@latest init
  2. npm i
  3. npm i sass-embedded -D
  4. Create a file entrypoints/test.content.scss
  5. Run npm run dev or npm run build

Expected
A file named test.css should be generated in .output/chrome-mv3/content-scripts

Actual
The test.css file does not exist :(

System Info

System:
    OS: Windows 11 10.0.26100
    CPU: (16) x64 AMD Ryzen 9 6900HX with Radeon Graphics
    Memory: 11.68 GB / 27.69 GB
  Binaries:
    Node: 22.13.1 - C:\Program Files\nodejs\node.EXE
    npm: 11.1.0 - C:\Program Files\nodejs\npm.CMD
    pnpm: 10.7.1 - ~\AppData\Local\pnpm\pnpm.CMD
  Browsers:
    Edge: Chromium (132.0.2957.140)
    Internet Explorer: 11.0.26100.1882

Used Package Manager

npm

Validations

@PortalCube PortalCube added the pending-triage Someone (usually a maintainer) needs to look into this to see if it's a bug label Apr 16, 2025
@PortalCube PortalCube changed the title Unlisted CSS with Sass does not generate any css file Unlisted CSS using preprocessor does not build css file Apr 18, 2025
@PortalCube
Copy link
Author

I have submitted a PR to fix this issue. #1590

After further investigation, I found that the same issue not only with Sass but with all CSS preprocessors, so I have updated the title

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pending-triage Someone (usually a maintainer) needs to look into this to see if it's a bug
Projects
None yet
1 participant