Compare commits

..

No commits in common. "0bde69c7bf410ff3f2daaac2d18854ddee32c710" and "16c876569f134081431602d6c1dd073381500e86" have entirely different histories.

4 changed files with 2 additions and 37 deletions

View File

@ -173,36 +173,6 @@ function babelPluginPDFJSPreprocessor(babel, ctx) {
path.replaceWith(t.importExpression(source));
}
},
NewExpression(path) {
const { node } = path;
if (
t.isIdentifier(node.callee, { name: "URL" }) &&
node.arguments.length === 2
) {
const [arg1, arg2] = node.arguments;
if (
arg1.type === "StringLiteral" &&
arg1.value.endsWith(".wasm") &&
arg2.type === "MemberExpression"
) {
// This statement is generated by the Emscripten Compiler (emcc),
// however we're manually loading wasm-files and we want to ensure
// that bundlers will leave it alone; this *must* include Webpack.
arg1.leadingComments = [
{
type: "CommentBlock",
value: "webpackIgnore: true",
},
{
type: "CommentBlock",
value: "@vite-ignore",
},
];
}
}
},
"BlockStatement|StaticBlock": {
// Visit node in post-order so that recursive flattening
// of blocks works correctly.

View File

@ -1,4 +0,0 @@
const wasmUrl = new URL(
/*webpackIgnore: true*/
/*@vite-ignore*/
"qwerty.wasm", import.meta.url);

View File

@ -1 +0,0 @@
const wasmUrl = new URL("qwerty.wasm" , import.meta.url);

View File

@ -1,5 +1,5 @@
{
"stableVersion": "5.1.91",
"baseVersion": "e5fbf52405fbb092351ef1cda8f44fbae3a84473",
"versionPrefix": "5.2."
"baseVersion": "d86045eacbd6f8cc9cbe8fd616800ca3edcbd0dc",
"versionPrefix": "5.1."
}