Closed vnbaaij closed 1 year ago
@vnbaaij what are you putting in your Microsoft.AspNetCore.StaticWebAssets.props
file.
I expect the order of the lines in the .props file to not have any influence on the working of an application that consumes my package.
Order absolutely matters in MSBuild. See here for details.
If this is an issue at all (which I do not necessarily thing it is) is likely a bug in your own targets/props files, unless you have a binlog that shows exactly that some evaluation of the pipeline does not reflect the defined behavior by MSBuild.
Hi @vnbaaij. We have added the "Needs: Author Feedback" label to this issue, which indicates that we have an open question for you before we can take further action. This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.
@vnbaaij Vincent Baaij FTE what are you putting in your
Microsoft.AspNetCore.StaticWebAssets.props
file.
That contains just the standard generated static assets xml (i.e. generated from the files in the wwwroot
folder):
<Project>
<ItemGroup>
<StaticWebAsset Include="$([System.IO.Path]::GetFullPath($(MSBuildThisFileDirectory)..\staticwebassets\Components\Anchor\FluentAnchor.razor.js))">
<SourceType>Package</SourceType>
<SourceId>Microsoft.Fast.Components.FluentUI</SourceId>
<ContentRoot>$(MSBuildThisFileDirectory)..\staticwebassets\</ContentRoot>
<BasePath>_content/Microsoft.Fast.Components.FluentUI</BasePath>
<RelativePath>Components/Anchor/FluentAnchor.razor.js</RelativePath>
<AssetKind>All</AssetKind>
<AssetMode>All</AssetMode>
<AssetRole>Primary</AssetRole>
<RelatedAsset></RelatedAsset>
<AssetTraitName></AssetTraitName>
<AssetTraitValue></AssetTraitValue>
<CopyToOutputDirectory>Never</CopyToOutputDirectory>
<CopyToPublishDirectory>PreserveNewest</CopyToPublishDirectory>
<OriginalItemSpec>$([System.IO.Path]::GetFullPath($(MSBuildThisFileDirectory)..\staticwebassets\Components\Anchor\FluentAnchor.razor.js))</OriginalItemSpec>
</StaticWebAsset>
:
:
</ItemGroup>
</Project>
Hi @vnbaaij. We have added the "Needs: Author Feedback" label to this issue, which indicates that we have an open question for you before we can take further action. This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.
Thank you for contacting us. Due to a lack of activity on this discussion issue we're closing it in an effort to keep our backlog clean. If you believe there is a concern related to the ASP.NET Core framework, which hasn't been addressed yet, please file a new issue.
This issue will be locked after 30 more days of inactivity. If you still wish to discuss this subject after then, please create a new issue!
Is there an existing issue for this?
Describe the bug
In the
Microsoft.Fast.Components.FluentUI
package I'm using the package.props
file to define some properties. Everything works ok when consuming the package and running a Blazor Server or Blazor WebAssembly application stand-alone. The application does not load when run in a hosted Blazor WebAssembly project. The application then cannot find and load any static assets. The problem is solved by changing the order of the contents in the.props
file in the package.Contents of the props file when the error/hang occurs:
Contents of the props file when problem does not occur:
Expected Behavior
I expect the order of the lines in the
.props
file to not have any influence on the working of an application that consumes my package.Steps To Reproduce
-Create a NuGet package with a custom
.props
file that has more content then just theImport
statement where the import statement is last -Create a hosted Blazor project that consumes the package -Verify the app does not load when running it -Change the.props
file so the import statement comes first and recreate the package -Change the project to use the new package -Verify the app runs properlyIf a starting point is wanted, the https://github.com/microsoft/fast-blazor repo can be used for this.
Exceptions (if any)
No response
.NET Version
.NET 6, .NET 7
Anything else?