Skip to content
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

Accept item index as an argument for formatter function #127

Closed
mestaritonttu opened this issue Sep 24, 2018 · 3 comments
Closed

Accept item index as an argument for formatter function #127

mestaritonttu opened this issue Sep 24, 2018 · 3 comments

Comments

@mestaritonttu
Copy link
Contributor

Currently the formatter function takes value and timestamp. In Chartist, there is a labelInterpolationFnc that takes value and index. This allows showing only certain label items like so:
return index % 2 === 0 ? value : null;
This is useful for getting stuff as minimal as possible on mobile.

@junedchhipa
Copy link
Contributor

junedchhipa commented Sep 26, 2018

No problem, I can provide the third argument as index

@junedchhipa
Copy link
Contributor

Updated the docs too
https://apexcharts.com/docs/options/xaxis/#formatter

@yantavares
Copy link

Hi! Is this functionality still available? I could not find it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants