0.1.5 • Published 1 year ago

hdicli v0.1.5

Weekly downloads
-
License
-
Repository
-
Last release
1 year ago

Haneke Design Interface CLI

This is a CLI tool that generates TypeScript types, Superstruct validators and type guards from an OpenAPI schema.

How to use:

hdicli -u https://example.com/openapi.json -o ./output -t types.ts -s superstruct.ts -g guards.ts

Options

OptionAliasDescriptionOptional?
--url-uThe URL to the OpenAPI schema.
--outdir-oThe output directory for the generated files (Default: './')
--types-tThe name for the generated types file. (Default: 'types.ts')
--superstruct-sThe name for the generated superstruct file. (Default: 'superstruct.ts')
--guards-gThe name for the generated guards file. (Default: 'guards.ts')
--help-hShow help--
--version-vShow version number--

Installation & Usage

Install using npm:

npm install -g hdicli
hdicli -u https://example.com/openapi.json -o ./output -t types.ts -s superstruct.ts -g guards.ts

Using npx:

npx hdicli -u https://example.com/openapi.json -o ./output -t types.ts -s superstruct.ts -g guards.ts

This will generate three files in the output directory:

  • types.ts: Contains TypeScript types generated from the OpenAPI schema.
  • superstruct.ts: Contains Superstruct validators generated from the OpenAPI schema.
  • guards.ts: Contains type guards generated from the OpenAPI schema.
0.1.5

1 year ago

0.1.4

1 year ago

0.1.3

1 year ago

0.1.2

1 year ago

0.1.1

1 year ago

0.1.0

1 year ago

0.0.4

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago

1.0.0

1 year ago