export interface QMarkdownTagParts { script?: string style?: string template?: string } const getTemplate = (html?: string): string => { let content = '' if (html && html.length > 0) { const start = '" const lastIndex = html.lastIndexOf(end) if (startIndex > -1 && lastIndex > -1) { // grab the text content = html.substring(startIndex, lastIndex + end.length) } } return content } export default function getTagParts(html = ''): QMarkdownTagParts { const canUseDOM = !!( typeof window !== 'undefined' && window.document && window.document.createElement ) if (canUseDOM !== true) { return {} } const results: QMarkdownTagParts = {} let tag // we'll use document to separate out of the sections, // but we can't use it for the