Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

237
Views
How to Create and Track Values on Chart with Vertical Cursor React-Native-Chart-Kit

I built a chart using the react-native-chart-kit. I do not want to use any solid data points so I set the setDots={false} so it is just a clean line. I am trying to create a vertical cursor to track the line values and create a tool tip to show what the values are. I am trying to use the onDataPointClick function but it is not working - I am assuming it must use the dots for that.

Is there anyway to make the capability ?


    <LineChart
                                          data={{
                                            datasets: [
                                              {
                                                data: this.state.cryptoChartData,
                                                color: (opacity = 1) =>
                                                  `rgba(167, 199, 231, ${opacity})`,
                                              },
                                            ],
                                          }}
                                          onDataPointClick={() => {
                                            console.log('clicked');
                                          }}
                                          width={deviceWidth} // from react-native
                                          height={220}
                                          withDots={false}
                                          yAxisLabel="$"
                                          withInnerLines={false}
                                          chartConfig={{
                                            backgroundColor: '#ffffff',
                                            backgroundGradientFrom: '#ffffff',
                                            backgroundGradientTo: '#ffffff',
                                            fillShadowGradient: '#007AFF',
                                            fillShadowGradientOpacity: 1,
                                            decimalPlaces: 0, // optional, defaults to 2dp
                                            color: (opacity = 1) =>
                                              `rgba(0,0,0,${opacity})`,
                                            labelColor: (opacity = 1) =>
                                              `rgba(0,0,0,${opacity})`,
                                            style: {
                                              borderRadius: 1,
                                            },
                                          }}
                                          bezier
                                          getDotPo
                                          style={{
                                            marginVertical: 5,
                                            borderRadius: 16,
                                          }}
                                        />

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!