title: d3: How to add border to a circle on an if-condition?
body: <p>I am adding few circles to my d3 graph as below:</p>
  
  <pre><code> this.node = this.svg.append('g')
      .attr('class', 'nodes')
    .selectAll('circle')
    .data(graph.nodes)
    .enter().append('circle')
      .attr('r', 5)
      .attr('fill', (d) =&gt; { return this.color(d.group); })
      .on('click', this.mouseclick)
      .call(d3.drag()
          .on('start', this.dragstarted)
          .on('drag', this.dragged)
          .on('end', this.dragended));
  </code></pre>
  
  <p>Just like <code>d.group</code> used above, I have <code>d.error</code> present in my data which an either be <code>true</code> or <code>false</code>. How can I show a red border for the same node while its being appended (or later?) if <code>d.error === true</code>?</p>