Working C# MAUI Blazor on home windows and Android with no downside. On iOS I get the app beginning on my iPhone it doesn’t discover my JavaScript perform LoadBasicChart:
Microsoft.JSInterop.JSException: ‘Couldn’t discover ‘LoadBasicChart’
(‘LoadBasicChart’ was undefined).
@app://0.0.0.0/_framework/blazor.webview.js:1:337 forEach@[native
code] findFunction@app://0.0.0.0/_framework/blazor.webview.js:1:303
@app://0.0.0.0/_framework/blazor.webview.js:1:3326 Promise@[native
code]
beginInvokeJSFromDotNet@app://0.0.0.0/_framework/blazor.webview.js:1:3317
@app://0.0.0.0/_framework/blazor.webview.js:1:40716
@user-script:1:4:75 forEach@[native code] @user-script:1:4:45 world
code@app://0.0.0.0/evaluate:1:26′
My Index.html appears to be like like this:
...
<div id="blazor-error-ui">
An unhandled error has occurred.
<a href="" class="reload">Reload</a>
<a category="dismiss">🗙</a>
</div>
<script src="_framework/blazor.webview.js" autostart="false"></script>
<script src="vendor/js/charts.js"></script>
<script src="vendor/js/charts_app.js"></script>
...
As you possibly can see, chart.js is loaded there and charts_app.js has the LoadBasicChart perform which not may be discovered. If i put out the LoadBasicChart perform to the index.html then it will likely be discovered and known as.
So the charts.js information will not be loaded on iOS. Why and the way can this be fastened?