New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Convert .ts to .d.ts files #61
Conversation
This is a great change, thank you. I'm not a super-duper TypeScript expert, so that's why I did things the way I did. 🙂 Nonetheless, I actually did realize recently that I could still use typedoc with just .d.ts files and |
package.json
Outdated
"build:typedoc": "typedoc --target ES5 --out docs-tmp --theme markdown --excludePrivate --excludeNotExported --hideSources --hideBreadcrumbs ./src/types && node ./bin/generateTypeDocs && rm -fr docs-tmp", | ||
"build:types": "tsc --target ES5 -d --outDir ./ts-tmp ./src/types/*.ts && mv ./ts-tmp/*.d.ts ./ && rm -fr ts-tmp", | ||
"build:typedoc": "typedoc --target ES5 --out docs-tmp --theme markdown --excludePrivate --excludeNotExported --hideSources --includeDeclarations --hideBreadcrumbs ./src/types && node ./bin/generateTypeDocs && rm -fr docs-tmp", | ||
"build:types": "cp ./src/types/*.d.ts ./", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We might as well just put the .d.ts files at the top level, but I can change that later
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unfortunately it looks like this messes up the README a bit due to how typedoc works. E.g. some methods that are supposed to return void
now return any
, and the picker options and defaults are all gone... I wonder if there is still a way to fix this with just .d.ts
files, or if it's a limitation of typedoc and therefore we should stick to dummy TS files. Another tricky part is that typedoc is out-of-date, and upgrading results in a messed-up README file... this may need some additional work 😕
(yarn build
will rebuild the README file btw)
^ Short-term fix for the |
I think I can solve the remaining issues :) Please stay tuned |
The readme looked fine when I tested the PR 😅 |
Okay I did some researches:
But I could still fix the |
BTW: |
Ah, that's too bad. Thanks for doing the research, though! Looks like we should probably stick with the |
Good evening,
Some days ago I found out, that the picker types don't have a signature for
removeEventListener
, so I was about to create an issue. But then I though "Why don't you fix that?". Then I saw your types and the dummy classes and five shaved yaks later I'm here. (Yes I read the contribution guidelines.)This PR:
@ts-ignore
Feel free to review!