Very loose Typescript definitions
artola opened this issue · 1 comments
artola commented
The provided typings are very loose, for example at DownloadFileParams
for export_empty_as
. Many fields are just string
and no help about the values is provided.
I would recommend to strongly type them, like string
replace by 'foo' | 'bar'
or alternatively use TSDOC to document them:
export interface DownloadFileParams {
/** Valid values: `foo`, `bar`. */
export_empty_as?: string;
https://github.com/lokalise/node-lokalise-api/blob/master/src/interfaces/download_file_params.ts
I do believe that improving the documentation will be a big gain for DX, otherwise working with the Node API is very painful.
bodrovis commented
It's in the plans! Thank you for the feedback, we will definetely work on this when we have enough capacity. We hope to make this solution much better and more useful than it currently is :)