assertTypeSymbol
assertTypeSymbol
Section titled “assertTypeSymbol”Assert that a value is of type symbol, with type-narrowing.
import { assertTypeSymbol } from "@kensio/smartass";
const value: unknown = Symbol("id");
assertTypeSymbol(value);
// value is now narrowed to symbolSource
Section titled “Source”Source file: src/assert/type-symbol/type-symbol.assert.ts
