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

InvalidOperationException: No JavaScript runtime found. #116

Open
toseni opened this issue May 16, 2022 · 0 comments
Open

InvalidOperationException: No JavaScript runtime found. #116

toseni opened this issue May 16, 2022 · 0 comments

Comments

@toseni
Copy link

toseni commented May 16, 2022

While everything works fine locally using both Debug and Release configuration, after using published app error InvalidOperationException: No JavaScript runtime found. appeares.

I am using .NET 6 and Typeahead component.

I suspect this is caused by .NET 6 trimming. Default settings are that "removes unused members from types". Since GetJSRuntime uses reflection to get JSRuntime trimmer can not see that JSRuntime property is used and removed it.

Disabled trimming solved this issue for me, but is not suitable as long term solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant