rive-wasm
rive-wasm copied to clipboard
Errors during makeRenderer not catchable
We are using @rive-app/webgl2 in our projects. When the creation of the renderer fails, we see an error in the console, but are unable to catch it using an onLoadError callback or try/catching the Rive constructor.
The error on the console is TypeError: Cannot read properties of null (reading ’T’).
In order to let the creation of the renderer fail, one can disable hardware rendering in Chrome.
Reproducer:
- Navigate to "chrome://settings/system"
- Disable "Use hardware acceleration when available"
- Restart Chrome
- Navigate to https://jsfiddle.net/rzbp8woj/1/
Is there any way for us to implement our own fallback mechanism when the creation of the webgl2 renderer fails?