-
Notifications
You must be signed in to change notification settings - Fork 10k
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
Blazor WASM RC2 - static web asset - conflicting web root path. #26928
Comments
@LaughingJohn thanks for contacting us. This was an issue in the past too, just that the server file would silently override the client file. In RC2 as part of some changes we did, we "tuned" up the validation to ensure that no two assets end up in the same final path. Normally this is not an issue for RCLs since their files are placed under "_content/$(PackageId)" by default, but in the case of blazor webassembly applications they are placed on the root folder, so these conflicts can present themselves more often, that's why we warn you when this happens, since otherwise the content on the server project will silently override the content on the client. |
Ah, thanks @javiercn, makes sense. I did delete one and it all worked. Be nice to have some guidance around sharing resources between client & server projects, and maybe intellisense (for css, jss and file location) across projects. |
@LaughingJohn Feel free to file an issue and post a comment here to see if it has other supporters. We are starting our plans for .NET 6.0 and we are looking for this type of feedback. Having something like this will help us track the interest for the feature as well as specific improvements people is interested in. |
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. |
I have started getting ``C:\Program Files\dotnet\sdk\5.0.100-rc.2.20479.15\Sdks\Microsoft.NET.Sdk.Razor\build\netstandard2.0\Microsoft.NET.Sdk.Razor.StaticWebAssets.targets(208,5): error : The static web asset 'C:\Users\dimak.nuget\packages\blazorise.bootstrap\0.9.1.2\build..\staticwebassets\blazorise.bootstrap.css' has a conflicting web root path '/wwwroot/_content/Blazorise.Bootstrap/blazorise.bootstrap.css' with the project file 'wwwroot_content\Blazorise.Bootstrap\blazorise.bootstrap.css'.` So confirming the bug needs to be fixed. Really annoying to rollback VS... |
Hi,
This is more of a question, but I upgraded my solution to RC2 and am now getting the following:
I have a favicon in the root folder of both the client and the server. I'm guessing I can just delete one of them, but I wanted to understand what has changed between RC1 and RC2 because it was working OK before.
On a broader note, I do find the sharing of assets (Images, css, js etc) between Client and Server a bit confusing. If I put them all in just one place I lose intellisense in the other. Can you advise on best practice for sharing assets between the two?
The text was updated successfully, but these errors were encountered: