We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Any plans to add some react examples for this lib? Would be very usefull :)
The text was updated successfully, but these errors were encountered:
Something like this is working good:
import { useEffect, useRef } from 'react'; import TimeChart from 'timechart'; const Chart = () => { const chartRef = useRef<HTMLDivElement | null>(null); useEffect(() => { const data = []; for (let x = 0; x < 100; x++) { data.push({ x, y: Math.random() }); } const chart = new TimeChart(chartRef.current!, { series: [{ name: 'Random', data }], tooltip: true, zoom: { x: { autoRange: true }, y: { autoRange: true }, }, }); return () => chart.dispose(); }, []); return ( <div ref={chartRef} style={{ width: '100%', height: 500 }} /> ); }; export default Chart;
Sorry, something went wrong.
No branches or pull requests
Any plans to add some react examples for this lib? Would be very usefull :)
The text was updated successfully, but these errors were encountered: