[Bug] Cannot work when using with `@import 'tailwindcss/utilities.css'` in .scss
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 48/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- sass, scss, tailwindcss, typescript
- Domain
- build-system, tooling
Research direction
Use the linked reproduction as the starting point: run pnpm install and pnpm build, then inspect the generated CSS in dist. Focus on the interaction between @rsbuild/plugin-sass, .scss @import, disabled lightningcss-loader, and sass-loader; done means the Tailwind utilities import remains separate from the following .foo rule in the output.
Written by the indexing model from the issue text.
Description
Versions
pnpm dlx envinfo --system --npmPackages
System:
OS: macOS 14.6.1
CPU: (12) arm64 Apple M2 Max
Memory: 2.34 GB / 96.00 GB
Shell: 3.7.1 - /opt/homebrew/bin/fish
npmPackages:
@rsbuild/core: ^1.1.8 => 1.1.10
@rsbuild/plugin-sass: ^1.1.2 => 1.1.2
@rsdoctor/rspack-plugin: ^0.4.12 => 0.4.12
rsbuild-plugin-tailwindcss: ^0.0.3 => 0.0.3
tailwindcss: ^3.4.17 => 3.4.17
Details
When using this plugin with:
@rsbuild/plugin-sass- Using
@importin.scss - Disabling
lightningcss-loader
@import 'tailwindcss/utilities.css';
.foo {
color: red;
}
The tailwindcss could not work properly.
Debugging with Rsdoctor, it shows that the semicolon is removed by sass-loader.
Reproduce
https://github.com/colinaaa-reproductions/rsbuild-plugin-tailwindcss-scss-import
pnpm installpnpm build
Then, checkout the output CSS in dist, it would be something like:
@tailwind utilities.foo{color:red}
- Dominant language
- TypeScript
- Stars
- 54
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from rstackjs/rsbuild-plugin-tailwindcss
-
Difficulty 3/5 1-2 days Newbie friendliness 45/100
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
rstackjs/rsbuild-plugin-tailwindcss#17 · 7 comments · 5 reactions ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
rstackjs/rsbuild-plugin-tailwindcss#16 · 9 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
rstackjs/rsbuild-plugin-tailwindcss#7 · 5 comments ·
-
Dependency Dashboard Open
Difficulty 5/5 Over a week Newbie friendliness 10/100
All issues in rstackjs/rsbuild-plugin-tailwindcss
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Eynzof/Hermes-CN-Desktop#610 ·
-
bug clawsweeper:linked-pr-open clawsweeper:needs-live-repro clawsweeper:no-new-fix-pr impact:message-loss issue-rating: 🐚 platinum hermit P2 regression
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
calcite-components needs triage refactor
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
Esri/calcite-design-system#15203 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
danielmiessler/LifeOS#2218 ·