mirror of
https://github.com/MercuryWorkshop/scramjet.git
synced 2025-05-13 06:20:02 -04:00
more like untrustedtypes
This commit is contained in:
parent
92651ed66b
commit
6eb9b6f12c
5 changed files with 48 additions and 45 deletions
|
@ -17,8 +17,6 @@ import * as ESTree from "estree";
|
|||
// parent
|
||||
|
||||
export function rewriteJs(js: string, origin?: URL) {
|
||||
const htmlcomment = /<!--[\s\S]*?-->/g;
|
||||
js = js.replace(htmlcomment, "");
|
||||
try {
|
||||
const ast = parseModule(js, {
|
||||
module: true,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue