You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At Datadog, we've built our "solution": we used yarn patch to simply erase Float32Array as a type. TypeScript now treats gl-matrix objects as tuples.
The downside: without accepting Float32Array, it's hard to cast Float32Array to vec2. That's no problem if callers only use vec2.create() and vec2.fromValues(). But it's a problem if callers are allocating a Float32Array themselves and doing vector math on slices of it.
The text was updated successfully, but these errors were encountered:
noUncheckedIndexAccess
enabled, TypeScript gives the wrong types when destructuring:Related: #381.
At Datadog, we've built our "solution": we used
yarn patch
to simply eraseFloat32Array
as a type. TypeScript now treats gl-matrix objects as tuples.The downside: without accepting
Float32Array
, it's hard to castFloat32Array
tovec2
. That's no problem if callers only usevec2.create()
andvec2.fromValues()
. But it's a problem if callers are allocating a Float32Array themselves and doing vector math on slices of it.The text was updated successfully, but these errors were encountered: