Performance benchmark and test suite for Node.js JSON-schema validators, evaluating speed, spec compliance, and side-effects.
json-schema-benchmark is a benchmarking and testing suite for Node.js JSON-schema validators. It evaluates validators based on performance, compliance with the official JSON-schema test suite, and absence of side-effects, helping developers choose the most suitable validator for their needs.
Node.js developers, backend engineers, and teams working with JSON-schema validation who need to compare validator performance, correctness, and safety for data validation tasks.
It provides objective, comprehensive benchmarks that go beyond speed to include spec compliance and side-effect checks, offering a holistic view of validator quality that isn't available in individual validator documentation.
Benchmarks for Node.js JSON-schema validators
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Measures relative speed and test runs per second for over 20 validators, with clear charts and tables showing Ajv as the fastest at 17000 tests/sec.
Tests against the official JSON-schema test suite for draft6, identifying failing tests, with @exodus/schemasafe having only 8 failures.
Detects validators that alter input data or schemas, highlighting risks with libraries like revalidator which caused 818 side-effects.
Covers draft4, draft6, and draft7 versions, allowing developers to benchmark validators across common schema standards.
Uses specific validator versions (e.g., ajv 6.12.6) that may not reflect latest updates, and updates depend on community contributions.
Admits it doesn't account for advanced validator features like custom keywords or async validation, which could be crucial for some use cases.
Exclusively benchmarks Node.js validators, ignoring browser-based or other language implementations, limiting its scope.