You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Scaffolded host strips @source "./_scan/", so packaged modules' Tailwind classes are never compiled #290
Styles/_scan/ is where the CollectModuleAssets MSBuild target stages every module's
built .pages.js. It is the only way a packaged (NuGet) module's utility classes
reach the compiled CSS — a packaged module has no .tsx under src/modules/, so the @source "../../modules/**/Pages/**/*.tsx" glob cannot see it.
With the directive stripped, a scaffolded host stages those bundles on every build and
then scans none of them.
Reproduction
sm new project MyApp &&cd MyApp
sm install SimpleModule.Users
npm run build && dotnet build src/MyApp.Host
Any utility class used only by the packaged module's pages is absent from src/MyApp.Host/wwwroot/css/app.css.
Why it matters
Same silent-failure shape as #288: the page renders, some classes work (whatever another
package happens to use literally), and the rest do nothing. It reads as a broken module
rather than a missing @source root.
Note on the fix
The strip looks deliberate — a fresh scaffold has no Styles/_scan/ directory yet, and
Tailwind errors on an @source path that does not exist. So restoring the directive
likely needs the scaffold to create Styles/_scan/ (e.g. with a .gitkeep) so the first npm run build succeeds before any dotnet build has staged anything there.
Found while fixing #288 in #289; the Tailwind up-to-date check already tracks these
staged bundles, so only the missing @source root remains.
Activity
fix: complete the Tailwind input set and surface the declared bundle'…
fix: keep @source "./_scan/" in scaffolded app.css (#290)
ci: run the CLI template tests, which dotnet test skips
fix: scaffolded-project path assumptions (#283, #284, #287, #288, #290)…