MCPcopy Create free account
hub / github.com/Effect-TS/effect / requireString

Function requireString

packages/sql/pg/src/PgTypes.ts:295–296  ·  view source on GitHub ↗
(value: unknown, name: string)

Source from the content-addressed store, hash-verified

293}
294
295const requireString = (value: unknown, name: string): string =>
296 typeof value === "string" ? value : fail(`Expected a string for ${name}`)
297
298const requireBigInt = (value: unknown, name: string): bigint =>
299 typeof value === "bigint" ? value : fail(`Expected a bigint for ${name}`)

Callers 5

encodeNumericFunction · 0.85
encodeInetFunction · 0.85
uuidWordsFunction · 0.85
PgTypes.tsFile · 0.85
dateDaysFunction · 0.85

Calls 1

failFunction · 0.70

Tested by

no test coverage detected