Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/neo/backend/util/data.ts>ensureDataType

👩‍💻 Matrix and other math, accelerated by WebGPU and WASM
Latest
function ensureDataType
import { ensureDataType } from "https://deno.land/x/neo@0.0.1-pre.1/backend/util/data.ts";

Ensures that all DataTypes match the type parameter

Parameters

type: T

The target DataType which we want all other types to match

...types: DataType[]

An arbitrary number of DataTypes which we want to match type

Returns

If successful type otherwise it throws a TypeError