@bastou/jsontotsinterface

1.0.1 • Public • Published

Json to typescript interface generator

Get json from url and export it to a typescript interface file with specified root name.

How to use

  • -n : (Optional) Interface name (default: RootObject)
  • -i : Input url or path to json
  • -o : Output path for generated Typescript interface file

Example :

node index.js -n=redditPopular -i=https://www.reddit.com/r/popular.json -o=./types/redditPopularInterface.ts  

Credits

@mariusalsh

Package Sidebar

Install

npm i @bastou/jsontotsinterface

Weekly Downloads

23

Version

1.0.1

License

ISC

Unpacked Size

179 kB

Total Files

22

Last publish

Collaborators

  • bastiencornier