Say I have some attributes I want to conditionally show on an element.
I cant do autoplay={false} because for HTML the fact that the attrivute is there at all , means it's true.
Would like the attribute to only be added it ift's true
<video
class:list={classList}
autoplay={autoplay}
loop="true"
playsinline
controls="false"
muted="true"
preload="auto"
width="640"
height="264"
data-setup="{}"
{/* If the link is an .m3u8 link, type="application/x-mpegURL" */}
{videoLink.includes('.m3u8') && <source src={videoLink} type="application/x-mpegURL" />}
{/* If the link is an .mp4 link, type="video/mp4" */}
{videoLink.includes('.mp4') && <source src={videoLink} type="video/mp4" />}
<p class="vjs-no-js">
To view this video please enable JavaScript, and consider upgrading to a web browser that
<a href="https://videojs.com/html5-video-support/" target="_blank">supports HTML5 video</a>
</p>
</video>