Comments (1)
Here's how to get the x axis labels
const xAxisLabels = chartContext.w.globals.labels
and the index
const selectedIndex = config.labelIndex
value
console.log(xAxisLabels[selectedIndex])
As far as I've read the docs, it does not provide any info on the params.
I found this by chance when I was reading the docs for this pie chart demo and figured it out when I was looking at the formatter in dataLabels. Please add documentation for this or at least make it accessible
from react-apexcharts.
Related Issues (20)
- Uncaught ReferenceError: anno is not defined HOT 2
- xAxis labels are not truncated and cut off HOT 1
- Series stroke line disappearing when first value is null HOT 1
- Candlestick Chart | Render issue | On render the chart does not render until I apply selection to volume
- Error: React Synchronized Chart Line (TypeError: Cannot read properties of null (reading 'ttItems'))
- Annotations Points Bug: Unexpected PointAppearing
- X-axis label issue with less records | Incorrect x-axis labels
- Y-axis renders different in deployment and local dev HOT 1
- apexcharts.common.js:6 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'group') HOT 2
- Different colors for different datapoints for multi series chart
- Same Group but different hights
- [ChartID] Cannot read properties of undefined (reading 'node') HOT 2
- Dumbbell Colors: Choosing specific colors per each datapoint
- [TypeError] TypeError: Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'
- Bar Chart > Bar alignment issue
- Support for Different Bar Widths in a Single Bar Chart
- Get xAxis and yAxis with MouseMove event
- All Charts Displaying Same Data After State Update
- Data label touches the bar when the bar reaches the maximum yaxis count
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-apexcharts.