Skip to content

Commit

Permalink
Fix axis not redrawing
Browse files Browse the repository at this point in the history
  • Loading branch information
Florian FERBACH committed Jul 11, 2018
1 parent eec3d47 commit 0b462bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export default ({ d3 = window.d3, ...customConfiguration }) => {
.range([0, width - labelWidth]);

const draw = data => selection => {
const svg = selection.selectAll('svg').data(data);
const svg = selection.selectAll('.viewport').data(data);

svg.exit().remove();

Expand All @@ -62,7 +62,7 @@ export default ({ d3 = window.d3, ...customConfiguration }) => {
.attr('transform', `translate(${margin.left},${margin.top})`);

enteringViewport
.merge(selection.selectAll('svg'))
.merge(selection.selectAll('.viewport'))
.call(dropLine(config, xScale))
.call(axis(d3, config, xScale))
.call(bounds(config, xScale));
Expand Down

0 comments on commit 0b462bc

Please sign in to comment.