title: How to translate 'this' in D3 JavaScript to TypeScript?
body: <p>I know that 'this' in JavaScript has a different meaning than in in TypeScript, as per this article <a href="https://github.com/Microsoft/TypeScript/wiki/&#39;this&#39;-in-TypeScript" rel="nofollow noreferrer">'this' in TypeScript</a>. I have the following code in JavaScript used to create a thicker stroke on the selected node, and give all other nodes a smaller stroke.</p>
  
  <pre><code>node.on('click', function (d) {
     d3.selectAll('circle').attr('stroke-width', 1.5);
     d3.select(this).select('circle').attr('stroke-width', 5);
  })
  </code></pre>
  
  <p>In TypeScript I have</p>
  
  <pre><code>this.node.on('click', (d:any) =&gt; {
     this.node.selectAll('circle').attr('stroke-width', 1.5);
     [this is where I need help].select('circle').attr('stroke-width', 5);
  }
  </code></pre>