Skip to content

Commit

Permalink
docs(README): update info for typescript
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfy1339 committed Apr 16, 2024
1 parent e7d4341 commit f0aaee6
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,13 @@ There is one method for each REST API endpoint documented at [https://developer.

## TypeScript

Parameter and response types for all endpoint methods exported as `{ RestEndpointMethodTypes }`.

> [!IMPORTANT]
> As we use [conditional exports](https://nodejs.org/api/packages.html#conditional-exports), you will need to adapt your `tsconfig.json`. See the TypeScript docs on [package.json "exports"](https://www.typescriptlang.org/docs/handbook/modules/reference.html#packagejson-exports).
> As we use [conditional exports](https://nodejs.org/api/packages.html#conditional-exports), you will need to adapt your `tsconfig.json` by setting `"moduleResolution": "node16", "module": "node16"`.
>
> See the TypeScript docs on [package.json "exports"](https://www.typescriptlang.org/docs/handbook/modules/reference.html#packagejson-exports).<br>
> See this [helpful guide on transitioning to ESM](https://gist.github.com/sindresorhus/a39789f98801d908bbc7ff3ecc99d99c) from [@sindresorhus](https://github.com/sindresorhus)
Parameter and response types for all endpoint methods exported as `{ RestEndpointMethodTypes }`.

Example

Expand Down

0 comments on commit f0aaee6

Please sign in to comment.