Skip to main content
Module

x/silicon/deps.ts>assertInstanceOf

Deno module to generate images from source code using Aloxaf/silicon.
Go to Latest
function assertInstanceOf
import { assertInstanceOf } from "https://deno.land/x/silicon@v0.0.4/deps.ts";

Make an assertion that obj is an instance of type. If not then throw.

Type Parameters

T extends AnyConstructor

Parameters

actual: unknown
expectedType: T
optional
msg = [UNSUPPORTED]

Returns

asserts actual is GetConstructorType<T>