How to conditionally assign attribute value in angular 2?
<p>I'm trying to learn the Angular 2. I have a simple material input tag and I wish to set it's value on a conditon.</p>

<pre><code>&lt;md-input value="dataSelected ? {{selectedDataName}} : ''"&gt;&lt;/md-input&gt;
</code></pre>

<p>I tried to set [value] or dataSelected as {{dataSelected}} or (dataSelected) but it doesn't do the trick.
Can someone lead me into right direction?</p>