Skip to content

Instantly share code, notes, and snippets.

@JakenHerman
Created December 8, 2020 05:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JakenHerman/813738d016863b6e12bc494851d692d7 to your computer and use it in GitHub Desktop.
Save JakenHerman/813738d016863b6e12bc494851d692d7 to your computer and use it in GitHub Desktop.
lineDecorators = [
{ cx: getX(0), cy: 30 },
{ cx: getX(50), cy: 30 },
{ cx: getX(100), cy: 30 },
{ cx: getX(0), cy: 60 },
{ cx: getX(50), cy: 60 },
{ cx: getX(100), cy: 60 },
{ cx: getX(0), cy: 90 },
{ cx: getX(50), cy: 90 },
{ cx: getX(100), cy: 90 },
{ cx: getX(0), cy: 120 },
{ cx: getX(50), cy: 120 },
{ cx: getX(100), cy: 120 }
];
decorators = svg.selectAll('#decor')
.data(lineDecorators)
.enter()
.append('circle')
.attr('id', 'decor')
.attr('cx', d => d.cx + 10 )
.attr('cy', d => d.cy)
.attr('r', 3)
.attr('fill', 'rgb(155, 155, 155)');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment