get-set-fetch / scraper

Nodejs web scraper. Contains a command line, docker container, terraform module and ansible roles for distributed cloud scraping. Supported databases: SQLite, MySQL, PostgreSQL. Supported headless clients: Puppeteer, Playwright, Cheerio, JSdom.
MIT License
107 stars 16 forks source link

correct json-schema handling of required properties #16

Open a1sabau opened 3 years ago

a1sabau commented 3 years ago

right now SchemaType generating a typescript type based on a json-schema doesn't support the "required" field. both required and optional json-schema properties result in optional typescript properties.

translate required json-schema props into required typescript props.