import { ScalarValidator } from "https://deno.land/x/abstruct@1.0.0/mod.ts";
Base validator for scalar.
Examples
import { ScalarValidator } from "https://deno.land/x/abstruct@$VERSION/validators/utils.ts";
import { ScalarValidator } from "https://deno.land/x/abstruct@$VERSION/validators/utils.ts";
class StringValidator extends ScalarValidator<unknown, string> { check(input: unknown): true | string { const typeOf = typeof input;
return typeOf === "string" || should be string, actual ${typeOf}
;
}
}