Skip to content

Commit 689a66c

Browse files
authored
feat: support template > script elements without type attribute (#72)
1 parent bd4327f commit 689a66c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/embed.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,9 @@ function initPlaygrounds() {
2020
markup = playground.content
2121
.querySelector('script[type="text/html"]')
2222
?.innerText.trim();
23+
2324
query = playground.content
24-
.querySelector('script[type="text/javascript"]')
25+
.querySelector('script[type="text/javascript"], script:not([type])')
2526
?.innerText.trim();
2627

2728
const compressed = compress({ markup, query });

0 commit comments

Comments
 (0)