-
Notifications
You must be signed in to change notification settings - Fork 8
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
Hotkeys2 and MAUI Blazor Hybrid compatibility #17
Comments
@tnglemongrass Thank you for letting me know about the problem. I must have overlooked the Blazor Hybrid scenario. As a workaround for a while, could you try to add one tnglemongrass/ToolbeltHotkeys2Demo#1 Actually, I've never tried that workaround on my side yet because I've been a bit busy these weeks. I'm sorry for that. Anyway, I hope the workaround above works well. (And I'd like to fix this problem someday.) |
@jsakamoto Yes, including that script tag fixes it. Thanks for looking into it and thanks a lot for that workaround! |
@jsakamoto I was also having the same issue when trying to run ilovedotnet blazor wasm project via blazor hybrid project... Adding the script as mentioned solves the exception. You can use https://github.com/ILoveDotNet/ilovedotnet/tree/main/MAUI to test. |
[FYI] See also: dotnet/maui#15234 Fortunately, I've verified the problem went away on the .NET 9 SDK Preview 5. So, please take the workaround of explicitly adding a script loading as below until the release of the .NET 9 SDK. <!-- wwwroot/index.html -->
<!-- 👇 Add this script tag before the script tag, which loads the "blazor.webview.js" JavaScript file. -->
<script src="_content/Toolbelt.Blazor.GetProperty.Script/Toolbelt.Blazor.GetProperty.Script.lib.module.js" type="module"></script> |
I try to use the Hotkeys2 library in a MAUI Blazor Hybrid App with .NET 8, following the instructions from the Hotkeys2 README.
Maybe there is just something missing in the README instructions?
Description:
When using the HotKeys2 library in a Maui Blazor Hybrid App, an error/warning is displayed on startup. However, the app runs fine and hotkeys work as expected.
Steps to Reproduce:
Expected Behavior:
There should be no errors or warnings on startup.
Actual Behavior:
The following error message is displayed on startup:
Additional Information:
The app runs fine and hotkeys work as expected, despite the error message.
A minimal reproducible example is here: https://github.com/tnglemongrass/ToolbeltHotkeys2Demo/
The text was updated successfully, but these errors were encountered: