how to concat string with dynamic value if that value exists
<p>Suppose I have a variable <code>data</code>:</p>

<pre><code>var data = 6;
</code></pre>

<p>If we have <code>data</code> value and it's greater than 5 then the output should be:</p>

<pre><code>"Hello x, 6 is your promo code"
</code></pre>

<p>If we don't have a <code>data</code> value, or the value is less than 5 then the output should be:</p>

<pre><code>"Hello x"
</code></pre>

<p>How can I do this with a single line of JavaScript?</p>