Releases: petamoriken/float16
Releases · petamoriken/float16
v3.4.12
- Fix: Stop using
Proxy
forFloat16Array
prototype methods (29b6eba) - Fix:
Float16Array
'sProxy
get/set handlers do not affect accessor properties not related toTypedArray
prototype (88ff220, e92d4e0) - Fix: Throw
TypeError
when inputBigUint64Array
/BigInt64Array
(47803fa) - Fix: Throw
TypeError
when@@species
doesn't returnTypedArray
or returnsBigUint64Array
/BigInt64Array
(572fe6e)
v3.4.11
- Fix types
- Fix custom inspect types for Deno
- Update README.md
v3.4.10
- Refactoring
- Update custom inspection
- Update README.md
v3.4.9
- Refactoring
- Update to use
.cjs
extension for CommonJS (24d6855) - Add custom inspection for Node.js and Deno (6ec5f2f)
Float16Array
custom inspection
Provides custom inspection for Node.js and Deno, which makes the results of console.log
more readable.
Node.js
// ES Modules
import { Float16Array } from "@petamoriken/float16";
import { customInspect } from "@petamoriken/float16/inspect";
Float16Array.prototype[Symbol.for("nodejs.util.inspect.custom")] = customInspect;
// CommonJS
const { Float16Array } = require("@petamoriken/float16");
const { customInspect } = require("@petamoriken/float16/inspect");
Float16Array.prototype[Symbol.for("nodejs.util.inspect.custom")] = customInspect;
Deno
import { Float16Array } from "https://deno.land/x/float16/mod.ts";
import { customInspect } from "https://deno.land/x/float16/inspect.ts";
// deno-lint-ignore no-explicit-any
(Float16Array.prototype as any)[Symbol.for("Deno.customInspect")] = customInspect;