gl-react
gl-react copied to clipboard
ReferenceError: Can't find variable: global
typedarray-pool attempts to use the global object here:
//Legacy pool support
if(!global.__TYPEDARRAY_POOL) {
global.__TYPEDARRAY_POOL = {
.......
}
}
I'm running TypeScript tsx files with vite. The code is little more than the HelloGL example at this point. Thoughts? It looks like typed array pool should probably be using globalThis, or a more elaborate section of code (like the one shown here: https://github.com/stephenh/ts-proto/issues/70#issuecomment-1638145123).
library version
├─┬ [email protected]
│ └── [email protected] deduped
└── [email protected]
For now I'm inserting a small script that sets global = {} in my index.html as a workaround.