You must be logged in to post your query.
Home › Forums › Chart Support › React itemClick with Boolean (JSFiddle given)
Tagged: ItemClick, React
MyTry
I am using itemClick function to render the second chart.
If the one of the x data point is clicked, the second chart is rendered.
How can I check if the x data is clicked or not?
MyRefer
I am referring the above link but I could not have found a proper way.
Please help me.
@wellhys,
You can render the second chart on clicking datapoints from the first chart using conditional rendering and react state. Please take a look at the code snippet below.
{this.state.clicked && <CanvasJSChart options={options} />}
Also, check out this StackBlitz for an example with complete code.
—- Manoj Mohan Team CanvasJS
You must be logged in to reply to this topic. Login/Register