mirror of
https://github.com/S2-/minifyfromhtml.git
synced 2025-08-04 04:40:05 +02:00
draft
This commit is contained in:
36
node_modules/ajv/lib/patternGroups.js
generated
vendored
Normal file
36
node_modules/ajv/lib/patternGroups.js
generated
vendored
Normal file
@@ -0,0 +1,36 @@
|
||||
'use strict';
|
||||
|
||||
var META_SCHEMA_ID = 'http://json-schema.org/draft-06/schema';
|
||||
|
||||
module.exports = function (ajv) {
|
||||
var defaultMeta = ajv._opts.defaultMeta;
|
||||
var metaSchemaRef = typeof defaultMeta == 'string'
|
||||
? { $ref: defaultMeta }
|
||||
: ajv.getSchema(META_SCHEMA_ID)
|
||||
? { $ref: META_SCHEMA_ID }
|
||||
: {};
|
||||
|
||||
ajv.addKeyword('patternGroups', {
|
||||
// implemented in properties.jst
|
||||
metaSchema: {
|
||||
type: 'object',
|
||||
additionalProperties: {
|
||||
type: 'object',
|
||||
required: [ 'schema' ],
|
||||
properties: {
|
||||
maximum: {
|
||||
type: 'integer',
|
||||
minimum: 0
|
||||
},
|
||||
minimum: {
|
||||
type: 'integer',
|
||||
minimum: 0
|
||||
},
|
||||
schema: metaSchemaRef
|
||||
},
|
||||
additionalProperties: false
|
||||
}
|
||||
}
|
||||
});
|
||||
ajv.RULES.all.properties.implements.push('patternGroups');
|
||||
};
|
Reference in New Issue
Block a user