UNPKG

@hyperjump/json-schema

Version:

A JSON Schema validator with support for custom keywords, vocabularies, and dialects

19 lines (12 loc) 443 B
import * as Browser from "@hyperjump/browser"; import * as Instance from "../instance.js"; const id = "https://json-schema.org/keyword/contentMediaType"; const compile = (schema) => Browser.value(schema); const interpret = () => true; const annotation = (contentMediaType, instance) => { if (Instance.typeOf(instance) !== "string") { return; } return contentMediaType; }; export default { id, compile, interpret, annotation };