1.0.6 • Published 14 days ago
flotiq-codegen-ts v1.0.6
flotiq-codegen-ts
This package generates Typescript Fetch API integration for your Flotiq project.
See it in action!
Go to this JSFiddle to see a (limited) demo.
Quickstart
npx flotiq-codegen-ts generate
Usage
Run flotiq-codegen-ts
, provide your API key and wait for your Typescript code to be generated in the flotiqApi
folder.
Then start using it:
import { FlotiqApi } from 'flotiqApi/src';
const FLOTIQ_RO_API_KEY = 'YOUR_API_KEY';
const flotiq = new FlotiqApi(FLOTIQ_RO_API_KEY);
// Use your IDE IntelliSense to work with types & api endpoints!
const eventList = await flotiq.Event.list({limit:100});
Generating declarations
To generate a set of d.ts
files for Typescript follow these steps:
- Execute
npx flotiq-codegen-ts generate
as usual - Go to
./flotiqApi
directory - Execute
npm run build
This will render the declarations in the flotiqApi/dist
folder.
Collaborating
If you wish to talk with us about this project, feel free to hop on our .
If you found a bug, please report it in issues.