Closed mirao closed 3 years ago
Motivation: To have working Resemble methods in TypeScript tests + autocompletion by IntelliSense in VSCode.
If TS definition doesn't exist, you get this in your TS test: If TS definition exists, everything works well:
I think it solves #77
I fixed:
options
I.see*
npx -p typescript tsc index.js --declaration --allowJs --emitDeclarationOnly
thanks a lot for your PR, I will prepare new version.
Motivation: To have working Resemble methods in TypeScript tests + autocompletion by IntelliSense in VSCode.
If TS definition doesn't exist, you get this in your TS test: If TS definition exists, everything works well:
I think it solves #77
I fixed:
options
in JSDoc was set as optional (https://jsdoc.app/tags-param.html#optional-parameters-and-default-values) so that generated TS definition allows omit it (otherwise TS check fails when callingI.see*
without that)npx -p typescript tsc index.js --declaration --allowJs --emitDeclarationOnly
, see https://www.typescriptlang.org/docs/handbook/declaration-files/dts-from-js.html