Generates Typescript types from the current version of resume-schema
.
This will be updated whenever resume-schema
is updated by using Dependabot to trigger the push workflow.
New versions will always match resume-schema
's version.
npm install @supastuff/json-resume-types --save
It's really only 1 type, but you can use "Lookup types" to get the types of sub properties:
import {ResumeSchema} from '@supastuff/json-resume-types'
function doStuff(work: ResumeSchema["work"]): void { ... }
The types are generated by json2ts
so some of it's issues came along for the ride:
Iso8601
doesn't keep it's regex pattern. You'll just have to trust that where ever you useIso8601
, it has the correct format- additionalProperties are defined as
[k: string]: unknown
. The unknown type may or may not cause problems for you. I think it's fine, but it sounds like there are complaints about it... issue#356, issue#335