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
Support TypeScript #139
Comments
Hi @FrankBrullo, thanks for opening this issue. Yes, we don't have TS types. Several people talked about it in https://github.com/eventbrite/britecharts/issues/223, but never came out of it yet. We are open to PRs though. |
Ok, I will do and let you know when the PR is ready. Thanks. |
That would be awesome @FrankBrullo!! Thanks a lot for doing this!! True, those handlers are not set, but they should. We would need to add them there as proptypes and they should be ready to use! |
@Golodhros That would be great! Thanks, |
I will try to go over it this weekend, but until we fix the release issue(hopefully next week) we won't be able to publish it. |
Let me know when you push your changes on Git so I can update my fork. |
Handlers Added! |
Hi @FrankBrullo, the handlers are ready and the release pipeline is working again! |
+1 for TS support. Give me a shout if you need any assistance @FrankBrullo :) |
Hi @miglesiasEB sorry for the radio silence but I got some issues to continue working on the PR. @dupski Thank you for the offer I will definitely take it! :) I will send you a preliminary PR for you to review because I am not much familiar with most of the chart and probably I will not have time to check all of them once I am done with the TS definitions. |
Same here regarding familiarity @FrankBrullo as I'm only just starting with this library but happy to take a look and give it a test :) |
Sounds good! We have a channel in the official d3 slack. Join us there @FrankBrullo ! |
Any motion on this? |
Not really, a lot of people offered to add the types but nobody actually did! |
I think It would be interesting to have this one, since some types can be reused. Anyway, we can start typing the props and the whole config before that gets merged. May I work on this ? :D |
Hi @ImADrafter! In my mind, the future should be a monorepo for britecharts, with @britecharts/core, @britecharts/react, @britecharts/types, @britecharts/angular and so on. If you have time to work on this stuff, I would actually love to get some help on making britecharts/britecharts#868 work. |
It seems that the library doesn't have the Typescript types defined.
I tried to do npm i @types/britecharts-react but the module doesn't exist.
I used
react-scripts-ts
to create my react test project.Below the TypeScript error I get from the compiler when I import the library:
Could not find a declaration file for module 'britecharts-react'. 'test-app/node_modules/britecharts-react/dist/britecharts-react.min.js' implicitly has an 'any' type.
Try
npm install @types/britecharts-react
if it exists or add a new declaration (.d.ts) file containingdeclare module 'britecharts-react';
The text was updated successfully, but these errors were encountered: