
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
@zeit/schemas
Advanced tools
The schemas contained within this package are used all across the ZEIT ecosystem to validate config files, requests to APIs and more. It ensures users always send just the right data.
It is important that these schemas stay in sync between projects, so that the validations are always performed in the same way for the same kind of object.
The files located in this repository are .js
and not .json
, because parsing JSON takes a little bit longer.
To get started, pick one of the schemas in this repository and load it:
const schema = require('@zeit/schemas/deployment/config');
Next, set up AJV (the validator) and run the schema through it:
const AJV = require('ajv');
const ajv = new AJV({ allErrors: true });
const isValid = ajv.validate(schema, <object-to-validate>);
if (!isValid) {
console.error(`The following entries are wrong: ${JSON.stringify(ajv.errors)}`);
}
That is all! :tada:
npm link
@zeit/schemas
, just link it to the dependencies: npm link @zeit/schemas
and load it!Leo Lamprecht (@notquiteleo) - ZEIT
FAQs
All schemas used for validation that are shared between our projects
The npm package @zeit/schemas receives a total of 1,220,497 weekly downloads. As such, @zeit/schemas popularity was classified as popular.
We found that @zeit/schemas demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 5 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.