@creopse/bridge 0.1.18 → 0.1.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/vite/react.js +1 -1
- package/dist/vite/vue.js +59 -56
- package/package.json +1 -1
package/dist/vite/react.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { D, S as L, s as M } from "../index-C8b1StIO.js";
|
|
2
|
-
import x from "
|
|
2
|
+
import x from "@originjs/vite-plugin-federation";
|
|
3
3
|
import O from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@vitejs+plugin-basic-ssl@2.3.0_vite@7.0.5_@types+node@24.0.15_jiti@2.6.1_tsx@4.21.0_/node_modules/@vitejs/plugin-basic-ssl/dist/index.mjs";
|
|
4
4
|
import { parse as R, stringify as j } from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/comment-json@4.6.2/node_modules/comment-json/src/index.js";
|
|
5
5
|
import v from "fs";
|
package/dist/vite/vue.js
CHANGED
|
@@ -1,62 +1,65 @@
|
|
|
1
|
-
import { D
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { parse as
|
|
5
|
-
import
|
|
1
|
+
import { D as E, S, s as O } from "../index-C8b1StIO.js";
|
|
2
|
+
import C from "@originjs/vite-plugin-federation";
|
|
3
|
+
import L from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/@vitejs+plugin-basic-ssl@2.3.0_vite@7.0.5_@types+node@24.0.15_jiti@2.6.1_tsx@4.21.0_/node_modules/@vitejs/plugin-basic-ssl/dist/index.mjs";
|
|
4
|
+
import { parse as x, stringify as M } from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/comment-json@4.6.2/node_modules/comment-json/src/index.js";
|
|
5
|
+
import w from "fs";
|
|
6
6
|
import i from "path";
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
function
|
|
13
|
-
const
|
|
14
|
-
if (
|
|
15
|
-
|
|
7
|
+
import j from "/Users/arkane/Dev/Projects/Web/creopse.proj/creopse.toolkit/node_modules/.pnpm/rollup-plugin-copy@3.5.0/node_modules/rollup-plugin-copy/dist/index.module.js";
|
|
8
|
+
import V from "vite-plugin-auto-import-lite";
|
|
9
|
+
import k from "vite-plugin-i18next-loader";
|
|
10
|
+
import N from "vite-plugin-json5";
|
|
11
|
+
import $ from "vite-plugin-top-level-await";
|
|
12
|
+
function B(g) {
|
|
13
|
+
const e = C(g);
|
|
14
|
+
if (console.debug("federation plugin keys:", Object.keys(e)), console.debug("resolveId type:", typeof e.resolveId), console.debug(
|
|
15
|
+
"resolveId descriptor:",
|
|
16
|
+
Object.getOwnPropertyDescriptor(e, "resolveId")
|
|
17
|
+
), e?.resolveId) {
|
|
18
|
+
const l = typeof e.resolveId == "function" ? e.resolveId : e.resolveId.handler, a = function(c, p, v) {
|
|
16
19
|
return p ? l.call(this, c, p, v) : null;
|
|
17
20
|
};
|
|
18
|
-
typeof
|
|
21
|
+
typeof e.resolveId == "function" ? e.resolveId = a : e.resolveId = { ...e.resolveId, handler: a };
|
|
19
22
|
}
|
|
20
|
-
return
|
|
23
|
+
return e;
|
|
21
24
|
}
|
|
22
25
|
function Q(g = {}) {
|
|
23
26
|
const {
|
|
24
|
-
manifestPath:
|
|
27
|
+
manifestPath: e = "./manifest.jsonc",
|
|
25
28
|
srcDir: l = "./src",
|
|
26
29
|
outDir: a = "frontend",
|
|
27
30
|
i18nLocalesPath: c,
|
|
28
31
|
composablesDirs: p = ["src/composables"],
|
|
29
32
|
shared: v = []
|
|
30
|
-
} = g,
|
|
31
|
-
let
|
|
32
|
-
const
|
|
33
|
-
let
|
|
33
|
+
} = g, d = process.cwd(), s = i.resolve(d, e), b = process.env.APP_IS_PREVIEW === "true";
|
|
34
|
+
let o;
|
|
35
|
+
const u = {};
|
|
36
|
+
let P = "creopse-plugin", h = "remoteEntry.js", I = 2160, y = 2161, A = !1;
|
|
34
37
|
try {
|
|
35
|
-
if (
|
|
36
|
-
const
|
|
37
|
-
if (
|
|
38
|
-
for (const m of
|
|
39
|
-
|
|
40
|
-
const t =
|
|
41
|
-
t?.module && (
|
|
42
|
-
const n =
|
|
43
|
-
n?.module && (
|
|
44
|
-
const f =
|
|
45
|
-
|
|
38
|
+
if (w.existsSync(s)) {
|
|
39
|
+
const r = w.readFileSync(s, "utf-8");
|
|
40
|
+
if (o = x(r || "{}"), o.pages && Array.isArray(o.pages))
|
|
41
|
+
for (const m of o.pages)
|
|
42
|
+
u[`./${m.name}`] = m.module;
|
|
43
|
+
const t = o.dashboard;
|
|
44
|
+
t?.module && (u[`./${E}`] = t.module);
|
|
45
|
+
const n = o.settings;
|
|
46
|
+
n?.module && (u[`./${S}`] = n.module);
|
|
47
|
+
const f = o.development;
|
|
48
|
+
P = O(String(o.id)) || P, h = o.entry || h, I = f?.previewPort || I, y = f?.serverPort || y, A = f?.ssl || A;
|
|
46
49
|
} else
|
|
47
50
|
console.warn(
|
|
48
51
|
`[CreopseVuePlugin] Warning: Manifest not found at ${s}`
|
|
49
52
|
);
|
|
50
|
-
} catch (
|
|
53
|
+
} catch (r) {
|
|
51
54
|
console.error(
|
|
52
55
|
"[CreopseVuePlugin] Fatal error while parsing manifest:",
|
|
53
|
-
|
|
56
|
+
r
|
|
54
57
|
);
|
|
55
58
|
}
|
|
56
|
-
const
|
|
59
|
+
const _ = c ? i.resolve(d, c) : i.resolve(d, l, "i18n/locales"), D = {
|
|
57
60
|
name: "creopse-vue-plugin",
|
|
58
|
-
config(
|
|
59
|
-
const t =
|
|
61
|
+
config(r) {
|
|
62
|
+
const t = r.root || d, n = i.resolve(t, a);
|
|
60
63
|
return {
|
|
61
64
|
envPrefix: "APP_",
|
|
62
65
|
resolve: {
|
|
@@ -70,16 +73,16 @@ function Q(g = {}) {
|
|
|
70
73
|
cssCodeSplit: !1,
|
|
71
74
|
rollupOptions: {
|
|
72
75
|
plugins: [
|
|
73
|
-
|
|
76
|
+
j({
|
|
74
77
|
targets: [
|
|
75
78
|
{
|
|
76
79
|
src: s,
|
|
77
80
|
dest: n,
|
|
78
81
|
transform() {
|
|
79
|
-
return
|
|
82
|
+
return o?.mode && (o.mode = b ? "development" : "production"), ((m) => m.replace(/(,)\s*\n/g, `,
|
|
80
83
|
|
|
81
84
|
`))(
|
|
82
|
-
|
|
85
|
+
M(o, null, 2)
|
|
83
86
|
);
|
|
84
87
|
}
|
|
85
88
|
}
|
|
@@ -97,44 +100,44 @@ function Q(g = {}) {
|
|
|
97
100
|
headers: { "Access-Control-Allow-Origin": "*" }
|
|
98
101
|
},
|
|
99
102
|
server: {
|
|
100
|
-
port:
|
|
103
|
+
port: y,
|
|
101
104
|
cors: !0,
|
|
102
105
|
headers: { "Access-Control-Allow-Origin": "*" }
|
|
103
106
|
}
|
|
104
107
|
};
|
|
105
108
|
},
|
|
106
|
-
configureServer(
|
|
107
|
-
|
|
109
|
+
configureServer(r) {
|
|
110
|
+
r.watcher.add(s), r.watcher.on("change", (t) => {
|
|
108
111
|
t === s && (console.info(
|
|
109
112
|
`
|
|
110
113
|
[CreopseVuePlugin] Manifest changed, restarting Vite...`
|
|
111
|
-
),
|
|
114
|
+
), r.restart());
|
|
112
115
|
});
|
|
113
116
|
}
|
|
114
117
|
};
|
|
115
118
|
return [
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
name:
|
|
119
|
-
filename:
|
|
120
|
-
exposes:
|
|
119
|
+
N(),
|
|
120
|
+
B({
|
|
121
|
+
name: P,
|
|
122
|
+
filename: h,
|
|
123
|
+
exposes: u,
|
|
121
124
|
shared: ["vue", "pinia", ...v]
|
|
122
125
|
}),
|
|
123
|
-
|
|
126
|
+
$({
|
|
124
127
|
promiseExportName: "__tla",
|
|
125
|
-
promiseImportName: (
|
|
128
|
+
promiseImportName: (r) => `__tla_${r}`
|
|
126
129
|
}),
|
|
127
|
-
|
|
128
|
-
paths: [
|
|
130
|
+
k({
|
|
131
|
+
paths: [_],
|
|
129
132
|
include: ["**/*.json"]
|
|
130
133
|
}),
|
|
131
|
-
|
|
134
|
+
V({
|
|
132
135
|
dirs: p,
|
|
133
136
|
imports: ["vue", "pinia"],
|
|
134
137
|
vueTemplate: !0
|
|
135
138
|
}),
|
|
136
|
-
...
|
|
137
|
-
|
|
139
|
+
...A ? [L()] : [],
|
|
140
|
+
D
|
|
138
141
|
];
|
|
139
142
|
}
|
|
140
143
|
export {
|