Socket
Socket
Sign inDemoInstall

ajv

Package Overview
Dependencies
5
Maintainers
2
Versions
351
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 8.6.3 to 8.7.0

10

dist/vocabularies/applicator/contains.js

@@ -55,2 +55,11 @@ "use strict";

gen.let(valid, false);
if (min === 0) {
gen.if((0, codegen_1._) `${data}.length > 0`, validateItemsWithCount, () => gen.assign(valid, true));
}
else {
validateItemsWithCount();
}
}
cxt.result(valid, () => cxt.reset());
function validateItemsWithCount() {
const schValid = gen.name("_valid");

@@ -60,3 +69,2 @@ const count = gen.let("count", 0);

}
cxt.result(valid, () => cxt.reset());
function validateItems(_valid, block) {

@@ -63,0 +71,0 @@ gen.forRange("i", 0, len, (i) => {

@@ -68,2 +68,11 @@ import type {

gen.let(valid, false)
if (min === 0) {
gen.if(_`${data}.length > 0`, validateItemsWithCount, () => gen.assign(valid, true))
} else {
validateItemsWithCount()
}
}
cxt.result(valid, () => cxt.reset())
function validateItemsWithCount(): void {
const schValid = gen.name("_valid")

@@ -73,3 +82,2 @@ const count = gen.let("count", 0)

}
cxt.result(valid, () => cxt.reset())

@@ -76,0 +84,0 @@ function validateItems(_valid: Name, block: () => void): void {

18

package.json
{
"name": "ajv",
"version": "8.6.3",
"version": "8.7.0",
"description": "Another JSON Schema Validator",

@@ -13,6 +13,6 @@ "main": "dist/ajv.js",

"scripts": {
"eslint": "eslint \"lib/**/*.ts\" \"spec/**/*.*s\" scripts --ignore-pattern spec/JSON-Schema-Test-Suite",
"eslint": "eslint \"lib/**/*.ts\" \"spec/**/*.*s\" --ignore-pattern spec/JSON-Schema-Test-Suite",
"prettier:write": "prettier --write \"./**/*.{json,yaml,js,ts}\"",
"prettier:check": "prettier --list-different \"./**/*.{json,yaml,js,ts}\"",
"test-spec": "cross-env TS_NODE_PROJECT=spec/tsconfig.json mocha -r ts-node/register \"spec/**/*.spec.{ts,js}\" -R dot -g \\(.recursiveRef.with.no..recursiveAnchor\\|.dynamicRef.with.no..dynamicAnchor\\).in.the.initial.target.schema.resource -i",
"test-spec": "cross-env TS_NODE_PROJECT=spec/tsconfig.json mocha -r ts-node/register \"spec/**/*.spec.{ts,js}\" -R dot",
"test-codegen": "nyc cross-env TS_NODE_PROJECT=spec/tsconfig.json mocha -r ts-node/register 'spec/codegen.spec.ts' -R spec",

@@ -27,6 +27,6 @@ "test-debug": "npm run test-spec -- --inspect-brk",

"test-all": "npm run test-cov && if-node-version 12 npm run test-browser",
"test": "npm run json-tests && npm run prettier:check && npm run eslint && npm link && npm link ajv && npm run test-cov",
"test": "npm run json-tests && npm run prettier:check && npm run eslint && npm link && npm link --legacy-peer-deps ajv && npm run test-cov",
"test-ci": "AJV_FULL_TEST=true npm test",
"prepublish": "npm run build",
"benchmark": "npm i && npm run build && npm link && cd ./benchmark && npm link ajv && npm i && node ./jtd",
"benchmark": "npm i && npm run build && npm link && cd ./benchmark && npm link --legacy-peer-deps ajv && npm i && node ./jtd",
"docs:dev": "./scripts/prepare-site && vuepress dev docs",

@@ -69,3 +69,3 @@ "docs:build": "./scripts/prepare-site && vuepress build docs"

"@ajv-validator/config": "^0.3.0",
"@rollup/plugin-commonjs": "^20.0.0",
"@rollup/plugin-commonjs": "^21.0.0",
"@rollup/plugin-json": "^4.1.0",

@@ -80,4 +80,3 @@ "@rollup/plugin-node-resolve": "^13.0.0",

"@typescript-eslint/parser": "^3.8.0",
"@vuepress/shared-utils": "^1.8.2",
"ajv-formats": "^2.0.0",
"ajv-formats": "^3.0.0-rc.0",
"chai": "^4.0.1",

@@ -107,4 +106,3 @@ "cross-env": "^7.0.2",

"tsify": "^5.0.2",
"typescript": "^4.2.0",
"vuepress": "^1.8.2"
"typescript": "^4.2.0"
},

@@ -111,0 +109,0 @@ "collective": {

@@ -18,24 +18,10 @@ <img align="right" alt="Ajv logo" width="160" src="https://ajv.js.org/img/ajv.svg">

## Platinum sponsors
## Ajv sponsors
[<img src="https://ajv.js.org/img/mozilla.svg" width="45%">](https://www.mozilla.org)<img src="https://ajv.js.org/img/gap.svg" width="8%">[<img src="https://ajv.js.org/img/reserved.svg" width="45%">](https://opencollective.com/ajv)
[<img src="https://ajv.js.org/img/mozilla.svg" width="45%" alt="Mozilla">](https://www.mozilla.org)<img src="https://ajv.js.org/img/gap.svg" width="9%">[<img src="https://ajv.js.org/img/reserved.svg" width="45%">](https://opencollective.com/ajv)
## Ajv online event - May 20, 10am PT / 6pm UK
[<img src="https://ajv.js.org/img/microsoft.png" width="31%" alt="Microsoft">](https://opensource.microsoft.com)<img src="https://ajv.js.org/img/gap.svg" width="3%">[<img src="https://ajv.js.org/img/reserved.svg" width="31%">](https://opencollective.com/ajv)<img src="https://ajv.js.org/img/gap.svg" width="3%">[<img src="https://ajv.js.org/img/reserved.svg" width="31%">](https://opencollective.com/ajv)
We will talk about:
- new features of Ajv version 8.
- the improvements sponsored by Mozilla's MOSS grant.
- how Ajv is used in JavaScript applications.
[<img src="https://ajv.js.org/img/retool.svg" width="22.5%" alt="Retool">](https://retool.com/?utm_source=sponsor&utm_campaign=ajv)<img src="https://ajv.js.org/img/gap.svg" width="3%">[<img src="https://ajv.js.org/img/tidelift.svg" width="22.5%" alt="Tidelift">](https://tidelift.com/subscription/pkg/npm-ajv?utm_source=npm-ajv&utm_medium=referral&utm_campaign=enterprise)<img src="https://ajv.js.org/img/gap.svg" width="3%">[<img src="https://ajv.js.org/img/reserved.svg" width="22.5%">](https://opencollective.com/ajv)<img src="https://ajv.js.org/img/gap.svg" width="3%">[<img src="https://ajv.js.org/img/reserved.svg" width="22.5%">](https://opencollective.com/ajv)
Speakers:
- [Evgeny Poberezkin](https://github.com/epoberezkin), the creator of Ajv.
- [Mehan Jayasuriya](https://github.com/mehan), Program Officer at Mozilla Foundation, leading the [MOSS](https://www.mozilla.org/en-US/moss/) and other programs investing in the open source and community ecosystems.
- [Matteo Collina](https://github.com/mcollina), Technical Director at NearForm and Node.js Technical Steering Committee member, creator of Fastify web framework.
- [Kin Lane](https://github.com/kinlane), Chief Evangelist at Postman. Studying the tech, business & politics of APIs since 2010. Presidential Innovation Fellow during the Obama administration.
- [Ulysse Carion](https://github.com/ucarion), the creator of JSON Type Definition specification.
[Gajus Kuizinas](https://github.com/gajus) will host the event.
Please [register here](https://us02web.zoom.us/webinar/register/2716192553618/WN_erJ_t4ICTHOnGC1SOybNnw).
## Contributing

@@ -88,2 +74,4 @@

<a href="https://opencollective.com/ajv/organization/9/website"><img src="https://opencollective.com/ajv/organization/9/avatar.svg"></a>
<a href="https://opencollective.com/ajv/organization/10/website"><img src="https://opencollective.com/ajv/organization/10/avatar.svg"></a>
<a href="https://opencollective.com/ajv/organization/11/website"><img src="https://opencollective.com/ajv/organization/11/avatar.svg"></a>

@@ -90,0 +78,0 @@ ## Performance

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc