import { isSymbol } from "https://deno.land/x/unknownutil@v3.16.1/mod.ts";
Return true
if the type of x
is symbol
.
import { is } from "https://deno.land/x/unknownutil@v3.16.1/mod.ts";
const a: unknown = Symbol("symbol");
if (is.Symbol(a)) {
// a is narrowed to symbol
const _: symbol = a;
}