-
Notifications
You must be signed in to change notification settings - Fork 9.8k
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
Error BLAZOR102 when using CSS preprocessing #39344
Comments
We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process. |
I don't know why I am getting this stupid ass message I am not using blazor at all wtf |
error BLAZOR102: Solution: |
Also having this issue at my work. The generated Scss files stays after switching branches, and thus creates this error. Is any solution found? |
Same issue as reported above . To test; I created new Blazor Server solution targeting .net 6. Then created Razor component CustomNotFound.razor and then CustomNotFound.razor.css. VS attaches the css file correctly but then throws error: Severity Code Description Project File Line Suppression State |
Same error as @KurtGarrettALS , @Albiniivari and others! my solution: deleted the component that was giving me the problem and restarted VS, recreate the component with new name! |
I had the same issue, was compiling my Sass files before I think |
I had a similar error, except it was for a In my case, I was running Using By removing the Summed up, by leaving |
The solution is to use |
I've updated https://github.com/JohnKiller/TestCopyFile to use
|
This issue has been resolved and has not had any activity for 1 day. It will be closed for housekeeping purposes. See our Issue Management Policies for more information. |
Is there an existing issue for this?
Describe the bug
Follow up of #38374 I've successfully managed to use the documentation to copy compiled files to the wwwroot folder using MSBuild.
Now I would like to do the same with Blazor scoped css, but every tutorial I've found just places the compiled CSS file inside the git repository instead of the recommended
obj/
folder.I've update my repo here https://github.com/JohnKiller/TestCopyFile
Inside
RazorClassLibrary1/RazorClassLibrary1.csproj
I've placed a fake compilation step that just copies the scss in theobj/
folder and then includes it:But this is the error I get:
obj\Debug\net6.0\Component1.razor.css : error BLAZOR102: The scoped css file 'obj\Debug\net6.0\Component1.razor.css' was defined but no associated razor component or view was found for it.
To me it looks like since the path is inside
obj\Debug
the framework misinterprets the path to be outside the component project location and refuses to bundle it.Expected Behavior
I would like this solution to work so I can avoid adding the compiled css file to the git repo and keep only the source scss. Using
.gitignore
is not an option because it causes the problem described in #38374Steps To Reproduce
Build https://github.com/JohnKiller/TestCopyFile
Exceptions (if any)
obj\Debug\net6.0\Component1.razor.css : error BLAZOR102: The scoped css file 'obj\Debug\net6.0\Component1.razor.css' was defined but no associated razor component or view was found for it.
.NET Version
6.0.101
Anything else?
No response
The text was updated successfully, but these errors were encountered: