Skip to content

Commit

Permalink
expose index for tickFormat (#615)
Browse files Browse the repository at this point in the history
  • Loading branch information
jckr committed Sep 19, 2017
1 parent 20005e6 commit 02ff490
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plot/axis/axis-ticks.js
Expand Up @@ -176,7 +176,7 @@ class AxisTicks extends React.Component {

const ticks = values.map((v, i) => {
const pos = scale(v);
const text = tickFormatFn(v);
const text = tickFormatFn(v, i);

return (
<g key={i} {...translateFn(pos, 0)}
Expand Down

0 comments on commit 02ff490

Please sign in to comment.