@jsonresume/schema 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +41 -16
- package/examples/career-changer.resume.json +1 -1
- package/examples/new-grad.resume.json +1 -1
- package/examples/senior-engineer.resume.json +1 -1
- package/job-schema.json +2 -5
- package/package.json +4 -2
- package/sample.resume.json +22 -7
- package/schema.json +82 -23
- package/validator.js +13 -0
package/README.md
CHANGED
|
@@ -18,30 +18,33 @@ npm install --save @jsonresume/schema
|
|
|
18
18
|
|
|
19
19
|
To use
|
|
20
20
|
|
|
21
|
+
`validate(resume, callback)` calls back with `(errors, valid)`:
|
|
22
|
+
|
|
21
23
|
```js
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
return;
|
|
29
|
-
}
|
|
30
|
-
console.log("Resume validated successfully:", report);
|
|
31
|
-
},
|
|
32
|
-
function (err) {
|
|
33
|
-
console.error("The resume was invalid:", err);
|
|
24
|
+
const { validate } = require('@jsonresume/schema');
|
|
25
|
+
|
|
26
|
+
validate({ basics: { name: 'Thomas' } }, (errors, valid) => {
|
|
27
|
+
if (!valid) {
|
|
28
|
+
console.error('The resume was invalid:', errors);
|
|
29
|
+
return;
|
|
34
30
|
}
|
|
35
|
-
);
|
|
31
|
+
console.log('Resume validated successfully');
|
|
32
|
+
});
|
|
36
33
|
```
|
|
37
34
|
|
|
38
35
|
Or against a full `resume.json`
|
|
39
36
|
|
|
40
37
|
```js
|
|
41
38
|
const fs = require('fs');
|
|
42
|
-
const
|
|
43
|
-
|
|
44
|
-
|
|
39
|
+
const { validate } = require('@jsonresume/schema');
|
|
40
|
+
|
|
41
|
+
const resume = JSON.parse(fs.readFileSync('./resume.json', 'utf8'));
|
|
42
|
+
validate(resume, (errors, valid) => {
|
|
43
|
+
if (!valid) {
|
|
44
|
+
console.error(errors);
|
|
45
|
+
process.exit(1);
|
|
46
|
+
}
|
|
47
|
+
});
|
|
45
48
|
```
|
|
46
49
|
|
|
47
50
|
The JSON Resume schema is available from:
|
|
@@ -50,6 +53,28 @@ The JSON Resume schema is available from:
|
|
|
50
53
|
require('@jsonresume/schema').schema;
|
|
51
54
|
```
|
|
52
55
|
|
|
56
|
+
### Extending with `custom`
|
|
57
|
+
|
|
58
|
+
Data with no standard field can go in an optional `custom` object, allowed at
|
|
59
|
+
the root, in `basics`, and on every entry of every section. Its contents are
|
|
60
|
+
free-form; namespace keys by tool to avoid collisions:
|
|
61
|
+
|
|
62
|
+
```json
|
|
63
|
+
{
|
|
64
|
+
"work": [
|
|
65
|
+
{
|
|
66
|
+
"name": "Tech Corp",
|
|
67
|
+
"position": "Senior Developer",
|
|
68
|
+
"custom": { "myAts": { "teamSize": 12, "directReports": 5 } }
|
|
69
|
+
}
|
|
70
|
+
]
|
|
71
|
+
}
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Themes don't render `custom`, and tools that read and write resumes should
|
|
75
|
+
preserve it unchanged. Unknown top-level properties are also still allowed
|
|
76
|
+
(`additionalProperties: true`); `custom` gives that data a predictable home.
|
|
77
|
+
|
|
53
78
|
### Contribute
|
|
54
79
|
|
|
55
80
|
We encourage anyone who's interested in participating in the formation of this standard to join the discussions [here on GitHub](https://github.com/jsonresume/jsonresume.org/issues). 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](http://editorconfig.org/) for your editor of choice.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://raw.githubusercontent.com/jsonresume/
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/jsonresume/jsonresume.org/master/packages/schema/schema.json",
|
|
3
3
|
"basics": {
|
|
4
4
|
"name": "Daniel Reyes",
|
|
5
5
|
"label": "Junior Data Analyst (former Restaurant Manager)",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://raw.githubusercontent.com/jsonresume/
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/jsonresume/jsonresume.org/master/packages/schema/schema.json",
|
|
3
3
|
"basics": {
|
|
4
4
|
"name": "Maya Okonkwo",
|
|
5
5
|
"label": "Computer Science Graduate",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://raw.githubusercontent.com/jsonresume/
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/jsonresume/jsonresume.org/master/packages/schema/schema.json",
|
|
3
3
|
"basics": {
|
|
4
4
|
"name": "Dr. Lena Vasquez",
|
|
5
5
|
"label": "Staff Software Engineer, Distributed Systems",
|
package/job-schema.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "http://json-schema.org/draft-
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "https://raw.githubusercontent.com/jsonresume/jsonresume.org/master/packages/schema/job-schema.json",
|
|
3
4
|
"additionalProperties": true,
|
|
4
5
|
"definitions": {
|
|
5
6
|
"iso8601": {
|
|
@@ -68,7 +69,6 @@
|
|
|
68
69
|
"responsibilities": {
|
|
69
70
|
"type": "array",
|
|
70
71
|
"description": "what the job entails",
|
|
71
|
-
"additionalItems": false,
|
|
72
72
|
"items": {
|
|
73
73
|
"type": "string",
|
|
74
74
|
"description": "e.g. Build out a new API for our customer base."
|
|
@@ -77,7 +77,6 @@
|
|
|
77
77
|
"qualifications": {
|
|
78
78
|
"type": "array",
|
|
79
79
|
"description": "List out your qualifications",
|
|
80
|
-
"additionalItems": false,
|
|
81
80
|
"items": {
|
|
82
81
|
"type": "string",
|
|
83
82
|
"description": "undergraduate degree, etc. "
|
|
@@ -86,7 +85,6 @@
|
|
|
86
85
|
"skills": {
|
|
87
86
|
"type": "array",
|
|
88
87
|
"description": "List out your professional skill-set",
|
|
89
|
-
"additionalItems": false,
|
|
90
88
|
"items": {
|
|
91
89
|
"type": "object",
|
|
92
90
|
"additionalProperties": true,
|
|
@@ -102,7 +100,6 @@
|
|
|
102
100
|
"keywords": {
|
|
103
101
|
"type": "array",
|
|
104
102
|
"description": "List some keywords pertaining to this skill",
|
|
105
|
-
"additionalItems": false,
|
|
106
103
|
"items": {
|
|
107
104
|
"type": "string",
|
|
108
105
|
"description": "e.g. HTML"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jsonresume/schema",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.4.0",
|
|
4
4
|
"description": "JSON Resume Schema",
|
|
5
5
|
"private": false,
|
|
6
6
|
"main": "validator.js",
|
|
@@ -25,7 +25,9 @@
|
|
|
25
25
|
"jsonschema": "^1.4.1"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
|
+
"ajv": "^8.17.1",
|
|
28
29
|
"ajv-cli": "^3.3.0",
|
|
30
|
+
"ajv-formats": "^3.0.1",
|
|
29
31
|
"json-metaschema": "^1.3.0",
|
|
30
32
|
"tap-spec": "^5.0.0",
|
|
31
33
|
"tape": "^4.16.2"
|
|
@@ -35,7 +37,7 @@
|
|
|
35
37
|
},
|
|
36
38
|
"scripts": {
|
|
37
39
|
"test": "npm run validate && npm run test-units",
|
|
38
|
-
"validate": "ajv validate -s node_modules/json-metaschema/draft-07-schema -d schema",
|
|
40
|
+
"validate": "ajv validate -s node_modules/json-metaschema/draft-07-schema -d schema -d job-schema",
|
|
39
41
|
"test-units": "tape **/*.spec.js | tap-spec"
|
|
40
42
|
}
|
|
41
43
|
}
|
package/sample.resume.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://raw.githubusercontent.com/jsonresume/
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/jsonresume/jsonresume.org/master/packages/schema/schema.json",
|
|
3
3
|
"basics": {
|
|
4
4
|
"name": "Richard Hendriks",
|
|
5
5
|
"label": "Programmer",
|
|
@@ -28,6 +28,7 @@
|
|
|
28
28
|
}
|
|
29
29
|
]
|
|
30
30
|
},
|
|
31
|
+
"objective": "Lead engineering for a compression-first storage platform.",
|
|
31
32
|
"work": [
|
|
32
33
|
{
|
|
33
34
|
"name": "Pied Piper",
|
|
@@ -42,7 +43,8 @@
|
|
|
42
43
|
"Build an algorithm for artist to detect if their music was violating copy right infringement laws",
|
|
43
44
|
"Successfully won Techcrunch Disrupt",
|
|
44
45
|
"Optimized an algorithm that holds the current world record for Weisman Scores"
|
|
45
|
-
]
|
|
46
|
+
],
|
|
47
|
+
"keywords": ["Compression", "C++", "Distributed Systems"]
|
|
46
48
|
}
|
|
47
49
|
],
|
|
48
50
|
"volunteer": [
|
|
@@ -65,7 +67,8 @@
|
|
|
65
67
|
"startDate": "2011-06-01",
|
|
66
68
|
"endDate": "2014-01-01",
|
|
67
69
|
"score": "4.0",
|
|
68
|
-
"courses": ["DB1101 - Basic SQL", "CS2011 - Java Introduction"]
|
|
70
|
+
"courses": ["DB1101 - Basic SQL", "CS2011 - Java Introduction"],
|
|
71
|
+
"summary": "Senior project on lossless compression for streaming media."
|
|
69
72
|
}
|
|
70
73
|
],
|
|
71
74
|
"awards": [
|
|
@@ -76,13 +79,25 @@
|
|
|
76
79
|
"summary": "There is no spoon."
|
|
77
80
|
}
|
|
78
81
|
],
|
|
82
|
+
"certificates": [
|
|
83
|
+
{
|
|
84
|
+
"name": "AWS Certified Solutions Architect – Associate",
|
|
85
|
+
"date": "2014-06-01",
|
|
86
|
+
"expiryDate": "2017-06-01",
|
|
87
|
+
"issuer": "Amazon Web Services",
|
|
88
|
+
"url": "https://certificates.example.com/aws/rhendriks",
|
|
89
|
+
"credentialId": "AWS-ASA-12345",
|
|
90
|
+
"summary": "Designing distributed systems on AWS."
|
|
91
|
+
}
|
|
92
|
+
],
|
|
79
93
|
"publications": [
|
|
80
94
|
{
|
|
81
95
|
"name": "Video compression for 3d media",
|
|
82
96
|
"publisher": "Hooli",
|
|
83
97
|
"releaseDate": "2014-10-01",
|
|
84
98
|
"url": "http://en.wikipedia.org/wiki/Silicon_Valley_(TV_series)",
|
|
85
|
-
"summary": "Innovative middle-out compression algorithm that changes the way we store data."
|
|
99
|
+
"summary": "Innovative middle-out compression algorithm that changes the way we store data.",
|
|
100
|
+
"type": "article"
|
|
86
101
|
}
|
|
87
102
|
],
|
|
88
103
|
"skills": [
|
|
@@ -134,8 +149,8 @@
|
|
|
134
149
|
}
|
|
135
150
|
],
|
|
136
151
|
"meta": {
|
|
137
|
-
"canonical": "https://raw.githubusercontent.com/jsonresume/
|
|
138
|
-
"version": "v1.
|
|
139
|
-
"lastModified": "
|
|
152
|
+
"canonical": "https://raw.githubusercontent.com/jsonresume/jsonresume.org/master/packages/schema/sample.resume.json",
|
|
153
|
+
"version": "v1.3.1",
|
|
154
|
+
"lastModified": "2026-10-22T00:00:00"
|
|
140
155
|
}
|
|
141
156
|
}
|
package/schema.json
CHANGED
|
@@ -1,12 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
-
"$id": "
|
|
3
|
+
"$id": "https://raw.githubusercontent.com/jsonresume/jsonresume.org/master/packages/schema/schema.json",
|
|
4
4
|
"additionalProperties": true,
|
|
5
5
|
"definitions": {
|
|
6
6
|
"iso8601": {
|
|
7
7
|
"type": "string",
|
|
8
|
-
"description": "Similar to the standard date type, but each section after the year is optional. e.g. 2014-06-29 or 2023-04",
|
|
9
|
-
"pattern": "^([1-2][0-9]{3}-[
|
|
8
|
+
"description": "Similar to the standard date type, but each section after the year is optional. e.g. 2014-06-29 or 2023-04. Every date is optional; omit endDate for a current position or ongoing entry (#309).",
|
|
9
|
+
"pattern": "^([1-2][0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])|[1-2][0-9]{3}-(0[1-9]|1[0-2])|[1-2][0-9]{3})$"
|
|
10
|
+
},
|
|
11
|
+
"custom": {
|
|
12
|
+
"type": "object",
|
|
13
|
+
"description": "Tool- or author-specific data that has no standard field yet (#316). Keys are free-form; namespace them by tool (e.g. \"myTool\": { ... }) to avoid collisions. Themes are not expected to render it, and tools should preserve it unchanged when reading and writing resumes.",
|
|
14
|
+
"additionalProperties": true
|
|
10
15
|
}
|
|
11
16
|
},
|
|
12
17
|
"properties": {
|
|
@@ -26,6 +31,10 @@
|
|
|
26
31
|
"type": "string",
|
|
27
32
|
"description": "e.g. Web Developer"
|
|
28
33
|
},
|
|
34
|
+
"pronouns": {
|
|
35
|
+
"type": "string",
|
|
36
|
+
"description": "e.g. she/her, they/them (#312)"
|
|
37
|
+
},
|
|
29
38
|
"image": {
|
|
30
39
|
"type": "string",
|
|
31
40
|
"description": "URL (as per RFC 3986) to a image in JPEG or PNG format"
|
|
@@ -75,7 +84,6 @@
|
|
|
75
84
|
"profiles": {
|
|
76
85
|
"type": "array",
|
|
77
86
|
"description": "Specify any number of social networks that you participate in",
|
|
78
|
-
"additionalItems": false,
|
|
79
87
|
"items": {
|
|
80
88
|
"type": "object",
|
|
81
89
|
"additionalProperties": true,
|
|
@@ -95,12 +103,18 @@
|
|
|
95
103
|
}
|
|
96
104
|
}
|
|
97
105
|
}
|
|
106
|
+
},
|
|
107
|
+
"custom": {
|
|
108
|
+
"$ref": "#/definitions/custom"
|
|
98
109
|
}
|
|
99
110
|
}
|
|
100
111
|
},
|
|
112
|
+
"objective": {
|
|
113
|
+
"type": "string",
|
|
114
|
+
"description": "Forward-looking career goal, e.g. 'Seeking a senior backend role in climate tech'. Distinct from basics.summary, which describes background (#317)"
|
|
115
|
+
},
|
|
101
116
|
"work": {
|
|
102
117
|
"type": "array",
|
|
103
|
-
"additionalItems": false,
|
|
104
118
|
"items": {
|
|
105
119
|
"type": "object",
|
|
106
120
|
"additionalProperties": true,
|
|
@@ -139,18 +153,27 @@
|
|
|
139
153
|
"highlights": {
|
|
140
154
|
"type": "array",
|
|
141
155
|
"description": "Specify multiple accomplishments",
|
|
142
|
-
"additionalItems": false,
|
|
143
156
|
"items": {
|
|
144
157
|
"type": "string",
|
|
145
158
|
"description": "e.g. Increased profits by 20% from 2011-2012 through viral advertising"
|
|
146
159
|
}
|
|
160
|
+
},
|
|
161
|
+
"keywords": {
|
|
162
|
+
"type": "array",
|
|
163
|
+
"description": "Skills, tools or technologies used in this role (#293)",
|
|
164
|
+
"items": {
|
|
165
|
+
"type": "string",
|
|
166
|
+
"description": "e.g. React"
|
|
167
|
+
}
|
|
168
|
+
},
|
|
169
|
+
"custom": {
|
|
170
|
+
"$ref": "#/definitions/custom"
|
|
147
171
|
}
|
|
148
172
|
}
|
|
149
173
|
}
|
|
150
174
|
},
|
|
151
175
|
"volunteer": {
|
|
152
176
|
"type": "array",
|
|
153
|
-
"additionalItems": false,
|
|
154
177
|
"items": {
|
|
155
178
|
"type": "object",
|
|
156
179
|
"additionalProperties": true,
|
|
@@ -181,18 +204,19 @@
|
|
|
181
204
|
"highlights": {
|
|
182
205
|
"type": "array",
|
|
183
206
|
"description": "Specify accomplishments and achievements",
|
|
184
|
-
"additionalItems": false,
|
|
185
207
|
"items": {
|
|
186
208
|
"type": "string",
|
|
187
209
|
"description": "e.g. Increased profits by 20% from 2011-2012 through viral advertising"
|
|
188
210
|
}
|
|
211
|
+
},
|
|
212
|
+
"custom": {
|
|
213
|
+
"$ref": "#/definitions/custom"
|
|
189
214
|
}
|
|
190
215
|
}
|
|
191
216
|
}
|
|
192
217
|
},
|
|
193
218
|
"education": {
|
|
194
219
|
"type": "array",
|
|
195
|
-
"additionalItems": false,
|
|
196
220
|
"items": {
|
|
197
221
|
"type": "object",
|
|
198
222
|
"additionalProperties": true,
|
|
@@ -227,11 +251,17 @@
|
|
|
227
251
|
"courses": {
|
|
228
252
|
"type": "array",
|
|
229
253
|
"description": "List notable courses/subjects",
|
|
230
|
-
"additionalItems": false,
|
|
231
254
|
"items": {
|
|
232
255
|
"type": "string",
|
|
233
256
|
"description": "e.g. H1302 - Introduction to American history"
|
|
234
257
|
}
|
|
258
|
+
},
|
|
259
|
+
"summary": {
|
|
260
|
+
"type": "string",
|
|
261
|
+
"description": "Thesis topic, honours, notable projects or other context (#292)"
|
|
262
|
+
},
|
|
263
|
+
"custom": {
|
|
264
|
+
"$ref": "#/definitions/custom"
|
|
235
265
|
}
|
|
236
266
|
}
|
|
237
267
|
}
|
|
@@ -239,7 +269,6 @@
|
|
|
239
269
|
"awards": {
|
|
240
270
|
"type": "array",
|
|
241
271
|
"description": "Specify any awards you have received throughout your professional career",
|
|
242
|
-
"additionalItems": false,
|
|
243
272
|
"items": {
|
|
244
273
|
"type": "object",
|
|
245
274
|
"additionalProperties": true,
|
|
@@ -258,6 +287,9 @@
|
|
|
258
287
|
"summary": {
|
|
259
288
|
"type": "string",
|
|
260
289
|
"description": "e.g. Received for my work with Quantum Physics"
|
|
290
|
+
},
|
|
291
|
+
"custom": {
|
|
292
|
+
"$ref": "#/definitions/custom"
|
|
261
293
|
}
|
|
262
294
|
}
|
|
263
295
|
}
|
|
@@ -265,7 +297,6 @@
|
|
|
265
297
|
"certificates": {
|
|
266
298
|
"type": "array",
|
|
267
299
|
"description": "Specify any certificates you have received throughout your professional career",
|
|
268
|
-
"additionalItems": false,
|
|
269
300
|
"items": {
|
|
270
301
|
"type": "object",
|
|
271
302
|
"additionalProperties": true,
|
|
@@ -282,9 +313,23 @@
|
|
|
282
313
|
"description": "e.g. http://example.com",
|
|
283
314
|
"format": "uri"
|
|
284
315
|
},
|
|
316
|
+
"credentialId": {
|
|
317
|
+
"type": "string",
|
|
318
|
+
"description": "Credential or licence number used to verify the certificate, e.g. a licence number or a certification ID (#590)"
|
|
319
|
+
},
|
|
285
320
|
"issuer": {
|
|
286
321
|
"type": "string",
|
|
287
322
|
"description": "e.g. CNCF"
|
|
323
|
+
},
|
|
324
|
+
"expiryDate": {
|
|
325
|
+
"$ref": "#/definitions/iso8601"
|
|
326
|
+
},
|
|
327
|
+
"summary": {
|
|
328
|
+
"type": "string",
|
|
329
|
+
"description": "What the certificate covers (#590)"
|
|
330
|
+
},
|
|
331
|
+
"custom": {
|
|
332
|
+
"$ref": "#/definitions/custom"
|
|
288
333
|
}
|
|
289
334
|
}
|
|
290
335
|
}
|
|
@@ -292,7 +337,6 @@
|
|
|
292
337
|
"publications": {
|
|
293
338
|
"type": "array",
|
|
294
339
|
"description": "Specify your publications through your career",
|
|
295
|
-
"additionalItems": false,
|
|
296
340
|
"items": {
|
|
297
341
|
"type": "object",
|
|
298
342
|
"additionalProperties": true,
|
|
@@ -316,6 +360,13 @@
|
|
|
316
360
|
"summary": {
|
|
317
361
|
"type": "string",
|
|
318
362
|
"description": "Short summary of publication. e.g. Discussion of the World Wide Web, HTTP, HTML."
|
|
363
|
+
},
|
|
364
|
+
"type": {
|
|
365
|
+
"type": "string",
|
|
366
|
+
"description": "e.g. 'article', 'book', 'patent', 'thesis', 'talk' (#295)"
|
|
367
|
+
},
|
|
368
|
+
"custom": {
|
|
369
|
+
"$ref": "#/definitions/custom"
|
|
319
370
|
}
|
|
320
371
|
}
|
|
321
372
|
}
|
|
@@ -323,7 +374,6 @@
|
|
|
323
374
|
"skills": {
|
|
324
375
|
"type": "array",
|
|
325
376
|
"description": "List out your professional skill-set",
|
|
326
|
-
"additionalItems": false,
|
|
327
377
|
"items": {
|
|
328
378
|
"type": "object",
|
|
329
379
|
"additionalProperties": true,
|
|
@@ -339,11 +389,13 @@
|
|
|
339
389
|
"keywords": {
|
|
340
390
|
"type": "array",
|
|
341
391
|
"description": "List some keywords pertaining to this skill",
|
|
342
|
-
"additionalItems": false,
|
|
343
392
|
"items": {
|
|
344
393
|
"type": "string",
|
|
345
394
|
"description": "e.g. HTML"
|
|
346
395
|
}
|
|
396
|
+
},
|
|
397
|
+
"custom": {
|
|
398
|
+
"$ref": "#/definitions/custom"
|
|
347
399
|
}
|
|
348
400
|
}
|
|
349
401
|
}
|
|
@@ -351,7 +403,6 @@
|
|
|
351
403
|
"languages": {
|
|
352
404
|
"type": "array",
|
|
353
405
|
"description": "List any other languages you speak",
|
|
354
|
-
"additionalItems": false,
|
|
355
406
|
"items": {
|
|
356
407
|
"type": "object",
|
|
357
408
|
"additionalProperties": true,
|
|
@@ -363,13 +414,15 @@
|
|
|
363
414
|
"fluency": {
|
|
364
415
|
"type": "string",
|
|
365
416
|
"description": "e.g. Fluent, Beginner"
|
|
417
|
+
},
|
|
418
|
+
"custom": {
|
|
419
|
+
"$ref": "#/definitions/custom"
|
|
366
420
|
}
|
|
367
421
|
}
|
|
368
422
|
}
|
|
369
423
|
},
|
|
370
424
|
"interests": {
|
|
371
425
|
"type": "array",
|
|
372
|
-
"additionalItems": false,
|
|
373
426
|
"items": {
|
|
374
427
|
"type": "object",
|
|
375
428
|
"additionalProperties": true,
|
|
@@ -380,11 +433,13 @@
|
|
|
380
433
|
},
|
|
381
434
|
"keywords": {
|
|
382
435
|
"type": "array",
|
|
383
|
-
"additionalItems": false,
|
|
384
436
|
"items": {
|
|
385
437
|
"type": "string",
|
|
386
438
|
"description": "e.g. Friedrich Nietzsche"
|
|
387
439
|
}
|
|
440
|
+
},
|
|
441
|
+
"custom": {
|
|
442
|
+
"$ref": "#/definitions/custom"
|
|
388
443
|
}
|
|
389
444
|
}
|
|
390
445
|
}
|
|
@@ -392,7 +447,6 @@
|
|
|
392
447
|
"references": {
|
|
393
448
|
"type": "array",
|
|
394
449
|
"description": "List references you have received",
|
|
395
|
-
"additionalItems": false,
|
|
396
450
|
"items": {
|
|
397
451
|
"type": "object",
|
|
398
452
|
"additionalProperties": true,
|
|
@@ -404,6 +458,9 @@
|
|
|
404
458
|
"reference": {
|
|
405
459
|
"type": "string",
|
|
406
460
|
"description": "e.g. Joe blogs was a great employee, who turned up to work at least once a week. He exceeded my expectations when it came to doing nothing."
|
|
461
|
+
},
|
|
462
|
+
"custom": {
|
|
463
|
+
"$ref": "#/definitions/custom"
|
|
407
464
|
}
|
|
408
465
|
}
|
|
409
466
|
}
|
|
@@ -411,7 +468,6 @@
|
|
|
411
468
|
"projects": {
|
|
412
469
|
"type": "array",
|
|
413
470
|
"description": "Specify career projects",
|
|
414
|
-
"additionalItems": false,
|
|
415
471
|
"items": {
|
|
416
472
|
"type": "object",
|
|
417
473
|
"additionalProperties": true,
|
|
@@ -427,7 +483,6 @@
|
|
|
427
483
|
"highlights": {
|
|
428
484
|
"type": "array",
|
|
429
485
|
"description": "Specify multiple features",
|
|
430
|
-
"additionalItems": false,
|
|
431
486
|
"items": {
|
|
432
487
|
"type": "string",
|
|
433
488
|
"description": "e.g. Directs you close but not quite there"
|
|
@@ -436,7 +491,6 @@
|
|
|
436
491
|
"keywords": {
|
|
437
492
|
"type": "array",
|
|
438
493
|
"description": "Specify special elements involved",
|
|
439
|
-
"additionalItems": false,
|
|
440
494
|
"items": {
|
|
441
495
|
"type": "string",
|
|
442
496
|
"description": "e.g. AngularJS"
|
|
@@ -456,7 +510,6 @@
|
|
|
456
510
|
"roles": {
|
|
457
511
|
"type": "array",
|
|
458
512
|
"description": "Specify your role on this project or in company",
|
|
459
|
-
"additionalItems": false,
|
|
460
513
|
"items": {
|
|
461
514
|
"type": "string",
|
|
462
515
|
"description": "e.g. Team Lead, Speaker, Writer"
|
|
@@ -469,6 +522,9 @@
|
|
|
469
522
|
"type": {
|
|
470
523
|
"type": "string",
|
|
471
524
|
"description": " e.g. 'volunteering', 'presentation', 'talk', 'application', 'conference'"
|
|
525
|
+
},
|
|
526
|
+
"custom": {
|
|
527
|
+
"$ref": "#/definitions/custom"
|
|
472
528
|
}
|
|
473
529
|
}
|
|
474
530
|
}
|
|
@@ -492,6 +548,9 @@
|
|
|
492
548
|
"description": "Using ISO 8601 with YYYY-MM-DDThh:mm:ss"
|
|
493
549
|
}
|
|
494
550
|
}
|
|
551
|
+
},
|
|
552
|
+
"custom": {
|
|
553
|
+
"$ref": "#/definitions/custom"
|
|
495
554
|
}
|
|
496
555
|
},
|
|
497
556
|
"title": "Resume Schema",
|
package/validator.js
CHANGED
|
@@ -4,6 +4,19 @@ const jobSchema = require('./job-schema');
|
|
|
4
4
|
const Validator = require('jsonschema').Validator;
|
|
5
5
|
|
|
6
6
|
function validate(resumeJson, callback) {
|
|
7
|
+
// jsonschema treats an absent instance as valid, which hides failed reads
|
|
8
|
+
// and parses upstream
|
|
9
|
+
if (
|
|
10
|
+
resumeJson === null ||
|
|
11
|
+
typeof resumeJson !== 'object' ||
|
|
12
|
+
Array.isArray(resumeJson)
|
|
13
|
+
) {
|
|
14
|
+
return callback(
|
|
15
|
+
[{ property: 'instance', message: 'resume must be a JSON object' }],
|
|
16
|
+
false
|
|
17
|
+
);
|
|
18
|
+
}
|
|
19
|
+
|
|
7
20
|
const v = new Validator();
|
|
8
21
|
|
|
9
22
|
const validation = v.validate(resumeJson, schema);
|