mirror of
https://git.boykissers.com/pawkey/pawkey-sk.git
synced 2025-12-20 12:14:18 +00:00
fix: unnecesary HMR when we opened setting page (#15756)
* refactor: add MarkerIdAssigner instead of processVueFile and remove transformedCodeCache object * chore: add minimatch, a glob matcher * chore: expose MarkerIdAssigner from plugin * Revert "chore: expose MarkerIdAssigner from plugin" This reverts commit 88c6d820f8635c35f1c15b4aac0987075d7cf8aa. * chore: add plugin to generate virtual module * chore: parse inlining earlier * chore: use virtual module in search * chore: use remove old generation * chore: fix type errors * chore: add patch to workaround vitejs/vite#19792 * chore: improve filtering files to process * chore: rename plugin * docs: add comment for plugin ordering * fix: unnecessary log * fix: spdx license header
This commit is contained in:
31
scripts/dependency-patches/vite.patch
Normal file
31
scripts/dependency-patches/vite.patch
Normal file
@@ -0,0 +1,31 @@
|
||||
diff --git a/dist/node/chunks/dep-DrOo5SEf.js b/dist/node/chunks/dep-DrOo5SEf.js
|
||||
index 329e68bd27e55a56d815fa6b4de2d615a8c2b343..9d9f58e90ae836f80063b698e307fec436e53e07 100644
|
||||
--- a/dist/node/chunks/dep-DrOo5SEf.js
|
||||
+++ b/dist/node/chunks/dep-DrOo5SEf.js
|
||||
@@ -45971,7 +45971,7 @@ function importAnalysisPlugin(config) {
|
||||
let isPartiallySelfAccepting = false;
|
||||
const importedBindings = enablePartialAccept ? /* @__PURE__ */ new Map() : null;
|
||||
const toAbsoluteUrl = (url) => path$d.posix.resolve(path$d.posix.dirname(importerModule.url), url);
|
||||
- const normalizeUrl = async (url, pos, forceSkipImportAnalysis = false) => {
|
||||
+ const normalizeUrl = async (url, pos, forceSkipImportAnalysis = false, stripBase2 = false) => {
|
||||
url = stripBase(url, base);
|
||||
let importerFile = importer;
|
||||
if (depsOptimizer && moduleListContains(depsOptimizer.options.exclude, url)) {
|
||||
@@ -46031,7 +46031,7 @@ function importAnalysisPlugin(config) {
|
||||
e.pos = pos;
|
||||
throw e;
|
||||
}
|
||||
- if (!ssr) url = joinUrlSegments(base, url);
|
||||
+ if (!ssr && !stripBase2) url = joinUrlSegments(base, url);
|
||||
return [url, resolved.id];
|
||||
};
|
||||
const orderedImportedUrls = new Array(imports.length);
|
||||
@@ -46288,7 +46288,7 @@ See ${colors$1.blue(
|
||||
const pluginImports = this._addedImports;
|
||||
if (pluginImports) {
|
||||
(await Promise.all(
|
||||
- [...pluginImports].map((id) => normalizeUrl(id, 0, true))
|
||||
+ [...pluginImports].map((id) => normalizeUrl(id, 0, true, true))
|
||||
)).forEach(([url]) => importedUrls.add(url));
|
||||
}
|
||||
if (ssr && importerModule.isSelfAccepting) {
|
||||
Reference in New Issue
Block a user