Skip to content

Commit

Permalink
fixed script tag
Browse files Browse the repository at this point in the history
  • Loading branch information
ecmel committed Sep 25, 2023
1 parent 55b8664 commit 58c6210
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const { parsers } = require("prettier/parser-html");

const regex =
/"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*'|<title.*?>.*?<\/title>|<textarea.*?>.*?<\/textarea>|(<%([^>]*?)%>)/gs;
/"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*'|<title.*?>.*?<\/title>|<textarea.*?>.*?<\/textarea>|<script.*?>.*?<\/script>|(<%([^>]*?)%>)/gs;

const replacer = (m, t, c) => (!t ? m : `<!${c}!>`);

Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "prettier-plugin-ejs",
"displayName": "Prettier EJS Plugin",
"version": "0.0.17",
"version": "0.0.18",
"description": "A Prettier plugin for Embedded JavaScript Templating (EJS).",
"keywords": [
"prettier",
Expand Down

0 comments on commit 58c6210

Please sign in to comment.