{#if token.type === 'html'} {#if html && html.includes(']*src="https:\/\/www\.youtube\.com\/embed\/([a-zA-Z0-9_-]{11})(?:\?[^"]*)?"[^>]*><\/iframe>/)} {@const match = token.text.match( /]*src="https:\/\/www\.youtube\.com\/embed\/([a-zA-Z0-9_-]{11})(?:\?[^"]*)?"[^>]*><\/iframe>/ )} {@const ytId = match && match[1]} {#if ytId} {/if} {:else if token.text.includes(`