MCPcopy Create free account
hub / github.com/denoland/std / isPrimitive

Function isPrimitive

assert/array_includes.ts:10–13  ·  view source on GitHub ↗
(value: unknown)

Source from the content-addressed store, hash-verified

8export type ArrayLikeArg<T> = ArrayLike<T> & object;
9
10function isPrimitive(value: unknown): boolean {
11 return value === null ||
12 typeof value !== "object" && typeof value !== "function";
13}
14
15/**
16 * Asserts that `actual` contains all values in `expected`, using deep equality

Callers 1

assertArrayIncludesFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected