Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: ajv-validator/ajv
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: cecd4ecca66abee0441a8277c647856b09454f82
Choose a base ref
...
head repository: ajv-validator/ajv
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: c067d6d9c3285054ea4c0a2d2adbbc8b5d631935
Choose a head ref
Loading
Showing 565 changed files with 38,460 additions and 18,438 deletions.
2 changes: 0 additions & 2 deletions .codeclimate.yml

This file was deleted.

30 changes: 30 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
const jsConfig = require("@ajv-validator/config/.eslintrc_js")
const tsConfig = require("@ajv-validator/config/.eslintrc")

module.exports = {
env: {
es6: true,
node: true,
},
overrides: [
jsConfig,
{
...tsConfig,
files: ["*.ts"],
rules: {
...tsConfig.rules,
complexity: ["error", 17],
"@typescript-eslint/no-empty-function": "off",
"@typescript-eslint/no-explicit-any": "off",
"@typescript-eslint/no-floating-promises": "off",
"@typescript-eslint/no-implied-eval": "off",
"@typescript-eslint/no-invalid-this": "off",
"@typescript-eslint/no-parameter-properties": "off",
"@typescript-eslint/no-unnecessary-condition": "warn",
"@typescript-eslint/no-unsafe-assignment": "off",
"@typescript-eslint/no-unsafe-member-access": "off",
"@typescript-eslint/restrict-template-expressions": "off",
},
},
],
}
29 changes: 0 additions & 29 deletions .eslintrc.yml

This file was deleted.

1 change: 1 addition & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
@epoberezkin
3 changes: 3 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
github: epoberezkin
tidelift: "npm/ajv"
open_collective: "ajv"
30 changes: 10 additions & 20 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,54 +1,47 @@
<!--
Frequently Asked Questions: https://github.com/epoberezkin/ajv/blob/master/FAQ.md
Frequently Asked Questions: https://ajv.js.org/faq.html
Please provide all info and reduce your schema and data to the smallest possible size.
This template is for bug reports. For other issues please use:
- a new feature/improvement: http://epoberezkin.github.io/ajv/contribute.html#changes
- browser/compatibility issues: http://epoberezkin.github.io/ajv/contribute.html#compatibility
- JSON-Schema standard: http://epoberezkin.github.io/ajv/contribute.html#json-schema
This template is for bug or error reports. For other issues please use:
- security vulnerability: https://tidelift.com/security)
- a new feature/improvement: https://ajv.js.org/contributing/#changes
- browser/compatibility issues: https://ajv.js.org/contributing/#compatibility
- JSON-Schema standard: https://ajv.js.org/contributing/#json-schema
- Ajv usage questions: https://gitter.im/ajv-validator/ajv
-->

**What version of Ajv are you using? Does the issue happen if you use the latest version?**



**Ajv options object**

<!-- See https://github.com/epoberezkin/ajv#options -->
<!-- See https://ajv.js.org/options.html -->

```javascript


```


**JSON Schema**

<!-- Please make it as small as possible to reproduce the issue -->

```json


```


**Sample data**

<!-- Please make it as small as posssible to reproduce the issue -->
<!-- Please make it as small as possible to reproduce the issue -->

```json


```


**Your code**

<!--
Please:
- make it as small as posssible to reproduce the issue
- use one of the usage patterns from https://github.com/epoberezkin/ajv#getting-started
- make it as small as possible to reproduce the issue
- use one of the usage patterns from https://ajv.js.org/guide/getting-started.html
- use `options`, `schema` and `data` as variables, do not repeat their values here
- post a working code sample in RunKit notebook cloned from https://runkit.com/esp/ajv-issue and include the link here.
@@ -58,10 +51,8 @@ Thank you!

```javascript


```


**Validation result, data AFTER validation, error messages**

```
@@ -71,5 +62,4 @@ Thank you!

**What results did you expect?**


**Are you going to resolve the issue?**
68 changes: 68 additions & 0 deletions .github/ISSUE_TEMPLATE/bug-or-error-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
---
name: Bug or error report
about: Please use for issues related to incorrect validation behaviour
title: ""
labels: "bug report"
assignees: ""
---

<!--
Frequently Asked Questions: https://ajv.js.org/faq.html
Please provide all info and reduce your schema and data to the smallest possible size.
This template is for bug or error reports.
For other issues please see https://ajv.js.org/contributing/
-->

**What version of Ajv are you using? Does the issue happen if you use the latest version?**

**Ajv options object**

<!-- See https://ajv.js.org/options.html -->

```javascript

```

**JSON Schema**

<!-- Please make it as small as possible to reproduce the issue -->

```json

```

**Sample data**

<!-- Please make it as small as possible to reproduce the issue -->

```json

```

**Your code**

<!--
Please:
- make it as small as possible to reproduce the issue
- use one of the usage patterns from https://ajv.js.org/guide/getting-started.html
- use `options`, `schema` and `data` as variables, do not repeat their values here
- post a working code sample in RunKit notebook cloned from https://runkit.com/esp/ajv-issue and include the link here.
It would make understanding your problem easier and the issue more useful to others.
Thank you!
-->

```javascript

```

**Validation result, data AFTER validation, error messages**

```
```

**What results did you expect?**

**Are you going to resolve the issue?**
23 changes: 23 additions & 0 deletions .github/ISSUE_TEMPLATE/change.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
---
name: Feature or change proposal
about: For proposals of new features, options or some other improvements
title: ""
labels: "enhancement"
assignees: ""
---

<!--
Frequently Asked Questions: https://ajv.js.org/faq.html
Please provide all info and reduce your schema and data to the smallest possible size.
This template is for change proposals.
For other issues please see https://ajv.js.org/contributing/
-->

**What version of Ajv you are you using?**

**What problem do you want to solve?**

**What do you think is the correct solution to problem?**

**Will you be able to implement it?**
27 changes: 27 additions & 0 deletions .github/ISSUE_TEMPLATE/compatibility.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
name: Browser and compatibility issue
about: For issues that only happen in a specific environment
title: ""
labels: "compatibility"
assignees: ""
---

<!--
Frequently Asked Questions: https://ajv.js.org/faq.html
Please provide all info and reduce your schema and data to the smallest possible size.
This template is for compatibility issues.
For other issues please see https://ajv.js.org/contributing/
-->

**The version of Ajv you are using**

**The environment you have the problem with**

**Your code (please make it as small as possible to reproduce the issue)**

**If your issue is in the browser, please list the other packages loaded in the page in the order they are loaded. Please check if the issue gets resolved (or results change) if you move Ajv bundle closer to the top**

**Results in node.js v8+**

**Results and error messages in your platform**
32 changes: 32 additions & 0 deletions .github/ISSUE_TEMPLATE/installation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
name: Installation and dependency issue
about: For issues that happen during installation
title: ""
labels: "installation"
assignees: ""
---

<!--
Frequently Asked Questions: https://ajv.js.org/faq.html
Please provide all info and reduce your schema and data to the smallest possible size.
This template is for installation and dependency issues.
For other issues please see https://ajv.js.org/contributing/
Before submitting the issue, please try the following:
- use the latest stable Node.js and npm
- use yarn instead of npm - the issue can be related to https://github.com/npm/npm/issues/19877
- remove node_modules and package-lock.json and run install again
-->

**The version of Ajv you are using**

**Operating system and node.js version**

**Package manager and its version**

**Link to (or contents of) package.json**

**Error messages**

**The output of `npm ls`**
36 changes: 36 additions & 0 deletions .github/ISSUE_TEMPLATE/typescript.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
---
name: Missing or incorrect type definition
about: Please use for issues related to typescript types
title: ""
labels: "typescript"
assignees: ""
---

<!--
Frequently Asked Questions: https://ajv.js.org/faq.html
This template is for issues about missing or incorrect type definition and other typescript-related issues.
For other issues please see https://ajv.js.org/contributing/
-->

**What version of Ajv are you using? Does the issue happen if you use the latest version?**

**Your typescript code**

<!--
Please make it as small as possible to reproduce the issue
-->

```typescript

```

**Typescript compiler error messages**

```
```

**Describe the change that should be made to address the issue?**

**Are you going to resolve the issue?**
4 changes: 1 addition & 3 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
Thank you for submitting a pull request to Ajv.
Before continuing, please read the guidelines:
https://github.com/epoberezkin/ajv/blob/master/CONTRIBUTING.md#pull-requests
https://github.com/ajv-validator/ajv/blob/master/CONTRIBUTING.md#pull-requests
If the pull request contains code please make sure there is an issue that we agreed to resolve (if it is a documentation improvement there is no need for an issue).
@@ -11,8 +11,6 @@ Please answer the questions below.

**What issue does this pull request resolve?**


**What changes did you make?**


**Is there anything that requires more attention while reviewing?**
32 changes: 32 additions & 0 deletions .github/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# Please supply comments to be used for GitHub labels
githubLabels:
bug: >
Bug confirmed - to be fixed. PR is welcome!
# duplicate: >
# enhancement: >
# good first issue: >
# help wanted: >
# invalid: >
# question: >
# wont fix: >

bug report: >
Thank you for the report! If you didn't post a code sample to RunKit yet,
please clone this notebook https://runkit.com/esp/ajv-issue,
post the code sample that demonstrates the bug and post the link here.
It will speed up the investigation and fixing!
json schema: >
This question is about the usage of JSON Schema specification - it is not specific to Ajv.
Please use JSON Schema reference materials or [submit the question to Stack Overflow](https://stackoverflow.com/questions/ask?tags=jsonschema,ajv).
- [JSON Schema specification](http://json-schema.org/)
- [Tutorial by Space Telescope Science Institute](http://json-schema.org/understanding-json-schema/)
- [validation keywords](https://github.com/ajv-validator/ajv#validation-keywords) (in Ajv docs)
- [combining schemas](https://github.com/ajv-validator/ajv#ref) (in Ajv docs)
- [Tutorial by @epoberezkin](https://code.tutsplus.com/tutorials/validating-data-with-json-schema-part-1--cms-25343)
Loading