title: How to set id in angular2 dynamically
body: <p>Is there anyway we can set id conditionally in angular2. Lets say I have a component template.</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;span id="setTextId()"&gt; </code></pre>
  </div>
  </div>
  </p>
  
  <p>I want to set my id return by this setTextId() function how can i do that?</p>