Add Schema type declaration
See original GitHub issue- Operating System: Ubuntu 16.04 LTS
- Node Version: 14.15.3
- NPM Version: 6.14.10
- webpack Version: ^4
- schema-utils Version: ^3
Feature Proposal
Please add standalone Schema type declaration.
Currently is possible to import it manually from validate method type declarations, but it is not convenient:
import * as schemaUtils from "schema-utils";
import { Schema } from "schema-utils/declarations/validate";
Feature Use Case
To use typed schema object, that is passed into validate method.
Issue Analytics
- State:
- Created 3 years ago
- Comments:11 (5 by maintainers)
Top Results From Across the Web
Creating element declarations in XML Schema: IU Only: Files
Step 1: Add a declaration for the simple element title. · Step 2: Declare the rest of the simple elements. · Step 3:...
Read more >XML Schema Example - W3Schools
This chapter will demonstrate how to write an XML Schema. ... with the standard XML declaration followed by the xs:schema element that defines...
Read more >Schemas and Types - GraphQL
Here, we're using a String type and marking it as Non-Null by adding an exclamation mark, ! after the type name. This means...
Read more >Mongoose v6.8.2: SchemaTypes
Mongoose plugins can also add custom SchemaTypes like int32. ... You can declare a schema type using the type directly, or an object...
Read more >Add Structured Data To Your How-To Pages | Documentation
The full definition of HowTo is available at schema.org/HowTo. The HowTo type indicates that the page contains a how-to. There must be one...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

I’ll probably make a PR when https://github.com/ajv-validator/ajv/issues/2180 is resolved currently TS is too strict and requires a complete rewrite of the schema which will turn it into a big breaking change
Yeah, it was implemented in the such way because
ajshad no types before, but a lot of things were changed, so PR welcome