Schema
/ API Reference / GuardsSchema
/ API Reference / GuardsisStringSchema
A function that checks if a JSON schema is an JSON string schema.
The Gist
import { isStringSchema, T_JSONSchema } from '@weser/schema'
const schema: T_JSONSchema = { type: 'string' }
const isString = isStringSchema(schema)
Parameters
Parameter | Type | Description |
---|---|---|
schema | T_JSONSchema | The JSON schema to check. |
Returns
(boolean
) Whether the schema is a string schema.
© 2024-present Robin Weser. All Rights Reserved.