-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
TypeScript definitions #197
Comments
@kodedevil, if you're willing to contribute with sankey definition, please link your PR to this issue :) |
We use TypeScript in our project that contains nivo. A lot of the times we just use an empty |
@plouc It seems like the current Typescript definitions for |
@kallebornemark, the doc says they're not required, but in fact they are required but defaultProps are defined, recent TypeScript version supports this, so the definitions should be updated :/ |
@plouc I see. Do you think still will happen anytime soon? We're looking for a sophisticated graph lib for our project, and yours looks really promising. We're very reliant on TS at the moment though. |
Not soon, I won't have much time to work on nivo in the upcoming weeks, but contributions are welcome :) All components have quite exhaustive prop types, it can help to write TS definitions. |
Support added for |
Definitions added for |
As I don't have time right now to submit a pr (I might later) I'll use this place to sum up typescript issues I find as I go: Bar v0.51
Pie v0.51 |
@SaphuA, thank you |
|
Hi, It seems that the |
Great work! I'm starting with typescript and nivo and these definitions are a blessing. I noticed two missing typings in
|
The |
Hi there, has the Typescript issue with borderColor in @nivo/bar (#344) been fixed? |
renderTick is still missing .. |
First of anything, thanks for the awesome work. Keep it up! :) I just realized, that the Types of the Axis' property
Since both seems to accept strings and components (at least |
Hi! just wanted to mention that there are some type definitions missing for the @nivo/core package, stumbled upon it while trying to use |
…ptions Some curve options where missing (basis, cardinal, catmullRom)
Hi @plouc , I am trying to add a total to the ResponsiveBar stacked bars from @nivo/bars using the Layer option. I have created my project with typescript so when I am adding the following line
Checking the type definitions for bars I can see it has types for Layers. Any idea where I am going wrong
If I change the line to |
It is because the layers you are passing in are coming as |
@plouc when trying to install |
@stephanoshadjipetrou It is on master but hasn't been made to a release. It will be in the next release, whenever that might be. |
@wyze thanks for the quick response! just another quick question: is this the same case for sunburst package? |
Yup! |
Thank you for the awesome effort. Any chance of adding Module
|
Seems like Treemap is missing tooltip. Any chance of adding it? |
Hi @maddy2894 and @mikejackowski please open separate issues specific to your requests and we can handle it there. Thanks! |
I see Pie is already checked as done, but I'm unable to import the type for data property (I expeted it to be PieDatum but it is not exported). Should I use some other type or is this a separate issue? |
This issue is used to track down the ongoing work on TypeScript definitions for nivo packages.
As nivo isn't built using TypeScript, it does not include definitions, if you're working in a TS environment and already created one for your use case, please do not hesitate to submit a PR!
@nivo/bar
ResponsiveBar - Add TypeScript definitions for Bar package #199@nivo/bar
ResponsiveBarCanvas - Add TypeScript definitions for Bar package #199@nivo/calendar
ResponsiveCalendar - Improve @nivo/calendar package #223@nivo/calendar
ResponsiveCalendarCanvas@nivo/chord
ResponsiveChord@nivo/chord
ResponsiveChordCanvas@nivo/circle-packing
ResponsiveBubble@nivo/circle-packing
ResponsiveBubbleHtml@nivo/circle-packing
ResponsiveBubbleCanvas@nivo/heatmap
ResponsiveHeatMap - Type declaration module for Heatmap package #198@nivo/heatmap
ResponsiveHeatMapCanvas - Type declaration module for Heatmap package #198@nivo/line
ResponsiveLine - feat(line): add typescript definitions #316@nivo/line
ResponsiveLineCanvas@nivo/pie
ResponsivePie - Definitions for Pie component #207@nivo/radar
ResponsiveRadar@nivo/sankey
ResponsiveSankey - feat(sankey): add TypeScript definitions #211@nivo/scatterplot
ResponsiveScatterPlot - feat(scatterplot): improve scatterplot #319@nivo/scatterplot
ResponsiveScatterPlotCanvas - feat(scatterplot): improve scatterplot #319@nivo/stream
ResponsiveStream@nivo/sunburst
ResponsiveSunburst@nivo/treemap
ResponsiveTreeMap@nivo/treemap
ResponsiveTreeMapHtml@nivo/treemap
ResponsiveTreeMapCanvas@nivo/waffle
ResponsiveWaffle - feat(waffle): add waffle package #202@nivo/waffle
ResponsiveWaffleHtml - feat(waffle): add waffle package #202@nivo/waffle
ResponsiveWaffleCanvas - feat(waffle): add waffle package #202The text was updated successfully, but these errors were encountered: