@eliasku/gl-matrix
v0.0.1
Published
gl-matrix typescript port (buildless)
Downloads
92
Readme
GL Matrix (TypeScript version)
Based on
[email protected]Buildless TypeScript distribution:
- copy to your project
- install and import
.tsfiles
Run Tests:
bun testshort arrow functions
() =>used instead of regular js functionsconstandletinstead ofvartype annotations in function declaration
CHANGELOG
- common round renamed to symround and add test
- skip
quat > setAxes > legacy exampletest - forced
Float32Arrayconstructor - remove degree/radians conversion. always use radians
- add
@__NO_SIDE_EFFECTS__annotation
No side-effect functions
Almost functions are PURE, but because of mutating out argument (pattern for optimization), we can't mark them. If we will mark all PURE function as PURE, so:
- with correct usage:
d = perspective(d, ...)function will not be stripped out - but just
perspective(d, ...)usage will be removed
Because of that these functions are not marked as no-side-effect.
Pure functions are marked with annotation /* @__NO_SIDE_EFFECTS__ */ for better treeshaking:
createArray, create, clone, str, frob, dot, length, squaredLength, fromValues, distance, squaredDistance, exactEquals, equals, fromRotationTranslationValues, getAngle, determinant
