diff --git a/packages/ui-templates/lib/render.ts b/packages/ui-templates/lib/render.ts index 7a1ff37d3c32..38ea09e2a6c3 100644 --- a/packages/ui-templates/lib/render.ts +++ b/packages/ui-templates/lib/render.ts @@ -80,7 +80,7 @@ export const RenderPlugin = () => { // Serialize into a js function const chunks = html.split(/\{{2,3}\s*[^{}]+\s*\}{2,3}/g).map(chunk => JSON.stringify(chunk)) - let hasMessages = chunks.length > 1 + const hasMessages = chunks.length > 1 let templateString = chunks.shift() for (const expression of html.matchAll(/\{{2,3}(\s*[^{}]+\s*)\}{2,3}/g)) { templateString += ` + (${expression[1].trim()}) + ${chunks.shift()}`