Is it possible to setup a ASP.NET Core MVC Blazor project to hot reload another project containing a component library? I think I saw it working once or twice but in the majority of cases it does not seem to work out of the box. Can I control it? Tried without success. Any hints?
- 1Could your kindly check the libray, it should be the best choice.buymeacoffee– buymeacoffee2023-04-05 10:06:34 +00:00Commented Apr 5, 2023 at 10:06
- Thank you Jason you sent me in the right direction ... I added this to my project ... '<ItemGroup> <Watch Include="..\..\Shared\UI\Web\TheComponentsComponents*.csproj" /> <Watch Include="..\..\Shared\UI\Web\TheComponentsComponents**.razor" /> <Watch Include="..\..\Shared\UI\Web\TheComponentsComponents***.cs" /> <Watch Remove="..\..\Shared\UI\Web\TheComponentsComponents\bin*" /> <Watch Remove="..\..\Shared\UI\Web\TheComponentsComponents\obj**" /> </ItemGroup>'mbr– mbr2023-04-05 14:51:58 +00:00Commented Apr 5, 2023 at 14:51
- Thanks for your feedback. I think it's the solution for your post. Could you summarzie it as answer below, it might help other forum users.buymeacoffee– buymeacoffee2023-04-06 05:36:56 +00:00Commented Apr 6, 2023 at 5:36
Add a comment |
1 Answer
Found a solution for it. I added those watch statements to my .csproj file. Be aware of the Remove statements. Otherwise it could watch files from another project.
<ItemGroup> <Watch Include="..\..\Shared\UI\Web\TheComponentsComponents\*.csproj" /> <Watch Include="..\..\Shared\UI\Web\TheComponentsComponents\**.razor" /> <Watch Include="..\..\Shared\UI\Web\TheComponentsComponents\***.cs" /> <Watch Remove="..\..\Shared\UI\Web\TheComponentsComponents\bin*" /> <Watch Remove="..\..\Shared\UI\Web\TheComponentsComponents\obj**" /> </ItemGroup>