@jsonresume/schema
v1.7.1
Published
JSON Resume Schema
Readme
JSON Resume Schema
Standard, Specification, Schema
Note: This package now lives in the jsonresume.org monorepo as
packages/schema(imported with full history from jsonresume/resume-schema). It keeps its npm identity as@jsonresume/schemaand is published from this workspace. Please open issues and PRs against the monorepo.
The current stable schema is represented by the files schema.json and sample.resume.json.
Getting started
npm install --save @jsonresume/schemaTo use
validate(resume, callback) calls back with (errors, valid):
const { validate } = require('@jsonresume/schema');
validate({ basics: { name: 'Thomas' } }, (errors, valid) => {
if (!valid) {
console.error('The resume was invalid:', errors);
return;
}
console.log('Resume validated successfully');
});Or against a full resume.json
const fs = require('fs');
const { validate } = require('@jsonresume/schema');
const resume = JSON.parse(fs.readFileSync('./resume.json', 'utf8'));
validate(resume, (errors, valid) => {
if (!valid) {
console.error(errors);
process.exit(1);
}
});The JSON Resume schema is available from:
require('@jsonresume/schema').schema;Extending with custom
Data with no standard field can go in an optional custom object, allowed at
the root, in basics, and on every entry of every section. Its contents are
free-form; namespace keys by tool to avoid collisions:
{
"work": [
{
"name": "Tech Corp",
"position": "Senior Developer",
"custom": { "myAts": { "teamSize": 12, "directReports": 5 } }
}
]
}Themes don't render custom, and tools that read and write resumes should
preserve it unchanged. Unknown top-level properties are also still allowed
(additionalProperties: true); custom gives that data a predictable home.
Contribute
We encourage anyone who's interested in participating in the formation of this standard to join the discussions here on GitHub. Also feel free to fork this project and submit new ideas to add to the JSON Resume Schema standard. To make sure all formatting is kept in check, please install the EditorConfig plugin for your editor of choice.
Versioning
JSON Resume Schema adheres to Semantic Versioning 2.0.0. If there is a violation of this scheme, report it as a bug. Specifically, if a patch or minor version is released and breaks backward compatibility, that version should be immediately yanked and/or a new version should be immediately released that restores compatibility. Any change that breaks the public API will only be introduced at a major-version release. As a result of this policy, you can (and should) specify any dependency on JSON Resume Schema by using the Pessimistic Version Constraint with two digits of precision.
Releases are managed from the monorepo with Changesets. Add a changeset describing your change and the appropriate version bump (patch/minor/major) in the same pull request.
major version bumps will be few and far between for this schema.
Job Description Schema
A draft schema for job descriptions is available in this project as well. It is not yet finalized, but we encourage you to check it out and provide feedback. See job-schema.json and sample.job.json.
The JSON Job schema is available from:
require('@jsonresume/schema').jobSchema;