I am trying to run mupdf built as web assembly in a webview on Android.
I have set the response headers correctly as far as I know, and this is illustrated by the fact that the web page using the web assembly works fine on desktop browsers and android browsers (including Chrome which uses a version of webview).
But when running a program of my own which uses a webview, the page when loaded gives a console message saying SharedArrayBuffer is not defined.
What I expect is that the webview in my program, when loading, should work the same as in the browsers. All other pages I use, with complex javascript, work the same way. But this one reaches the attempt to create a SharedArrayBuffer, and fails with an error in the console.
When I go to the page that tries to load the web assembly code, and which uses a Shared ArrayBuffer, I have checked and in every browser,
window.isSecureContext is true and window.crossOriginIsolated is true
however, in the webview in my program
window.isSecureContext is true BUT window.crossOriginIsolated is false