Skip to content
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

[browser] Suport for OutputType Library #89577

Closed
pavelsavara opened this issue Jul 27, 2023 · 4 comments
Closed

[browser] Suport for OutputType Library #89577

pavelsavara opened this issue Jul 27, 2023 · 4 comments
Labels
Milestone

Comments

@pavelsavara
Copy link
Member

pavelsavara commented Jul 27, 2023

currently WASM projects need to be <OutputType>Exe</OutputType>

use case: nuget library with component for Blazor, including [JSImport]

@pavelsavara pavelsavara added this to the 9.0.0 milestone Jul 27, 2023
@ghost
Copy link

ghost commented Jul 27, 2023

Tagging subscribers to this area: @directhex
See info in area-owners.md if you want to be subscribed.

Issue Details

currently WASM projects need to be <OutputType>Exe</OutputType>

Author: pavelsavara
Assignees: -
Labels:

arch-wasm, area-Infrastructure-mono

Milestone: 9.0.0

@maraf
Copy link
Member

maraf commented Jun 4, 2024

I'm slightly confused by the description. Is the goal here to produce a "wasm application without main" (the whole app bundle)? Or just be able to use [JSImport] in .NET library? For the latter, setting RuntimeIdentifier=browser-wasm should be sufficient. If the Microsoft.NET.Sdk.StaticWebAssets SDK is used, even the javascript files will be bundled correctly

@pavelsavara
Copy link
Member Author

For the "wasm application without main" what would be the use-case ?
Could we have blazor component with wasm functionality as nuget and then add that to non-wasm blazor project and expect it to work ?

Could we have dotnet wasm wrapped as react component and somehow flow it thru asp.net core in a way which would initialize the dotnet.js ?

I feel that the answer is probably not with nuget.

Could the same thing be achieved with npm package and node/webpack ecosystem ? Possibly yes.

@maraf
Copy link
Member

maraf commented Jun 4, 2024

If it's not the "wasm application without main" case, we can close the issue

@github-actions github-actions bot locked and limited conversation to collaborators Jul 5, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants