@modern-js/plugin-devtools 0.0.0-next-20231106062815 → 0.0.0-next-20231106082800
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/cli.js +4 -6
- package/package.json +15 -16
- package/dist/runtime.d.ts +0 -1
- package/dist/runtime.js +0 -11
package/dist/cli.js
CHANGED
|
@@ -62,7 +62,7 @@ const devtoolsPlugin = (options) => ({
|
|
|
62
62
|
res.end();
|
|
63
63
|
};
|
|
64
64
|
const useMainRoute = () => {
|
|
65
|
-
req.url = "/html/
|
|
65
|
+
req.url = "/html/client/index.html";
|
|
66
66
|
serveMiddleware(req, res, usePageNotFound);
|
|
67
67
|
};
|
|
68
68
|
serveMiddleware(req, res, useMainRoute);
|
|
@@ -89,9 +89,10 @@ const devtoolsPlugin = (options) => ({
|
|
|
89
89
|
const mountOpts = {
|
|
90
90
|
dataSource: `${import_devtools_kit.ROUTE_BASENAME}/rpc`,
|
|
91
91
|
endpoint: import_devtools_kit.ROUTE_BASENAME,
|
|
92
|
+
def: new import_devtools_kit.ClientDefinition(),
|
|
92
93
|
__keep: true
|
|
93
94
|
};
|
|
94
|
-
let runtimeEntry = require.resolve("@modern-js/
|
|
95
|
+
let runtimeEntry = require.resolve("@modern-js/devtools-client/mount");
|
|
95
96
|
runtimeEntry = (0, import_ufo.withQuery)(runtimeEntry, mountOpts);
|
|
96
97
|
return {
|
|
97
98
|
builderPlugins: [
|
|
@@ -100,10 +101,7 @@ const devtoolsPlugin = (options) => ({
|
|
|
100
101
|
source: {
|
|
101
102
|
preEntry: [
|
|
102
103
|
runtimeEntry
|
|
103
|
-
]
|
|
104
|
-
globalVars: {
|
|
105
|
-
"process.env._MODERN_DEVTOOLS_LOGO_SRC": new import_devtools_kit.ClientDefinition().assets.logo
|
|
106
|
-
}
|
|
104
|
+
]
|
|
107
105
|
},
|
|
108
106
|
tools: {
|
|
109
107
|
devServer: {
|
package/package.json
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"modern",
|
|
16
16
|
"modern.js"
|
|
17
17
|
],
|
|
18
|
-
"version": "0.0.0-next-
|
|
18
|
+
"version": "0.0.0-next-20231106082800",
|
|
19
19
|
"jsnext:source": "./src/index.ts",
|
|
20
20
|
"types": "./dist/index.d.ts",
|
|
21
21
|
"main": "./dist/index.js",
|
|
@@ -45,10 +45,9 @@
|
|
|
45
45
|
"p-defer": "^3.0.0",
|
|
46
46
|
"ws": "^8.13.0",
|
|
47
47
|
"ufo": "^1.3.0",
|
|
48
|
-
"@modern-js/devtools-kit": "0.0.0-next-
|
|
49
|
-
"@modern-js/
|
|
50
|
-
"@modern-js/
|
|
51
|
-
"@modern-js/devtools-client": "0.0.0-next-20231106062815"
|
|
48
|
+
"@modern-js/devtools-kit": "0.0.0-next-20231106082800",
|
|
49
|
+
"@modern-js/devtools-client": "0.0.0-next-20231106082800",
|
|
50
|
+
"@modern-js/utils": "0.0.0-next-20231106082800"
|
|
52
51
|
},
|
|
53
52
|
"devDependencies": {
|
|
54
53
|
"@types/serve-static": "^1.13.10",
|
|
@@ -57,19 +56,19 @@
|
|
|
57
56
|
"@types/ws": "^8.5.5",
|
|
58
57
|
"type-fest": "^4.1.0",
|
|
59
58
|
"typescript": "^5",
|
|
60
|
-
"@modern-js/app-tools": "0.0.0-next-
|
|
61
|
-
"@modern-js/core": "0.0.0-next-
|
|
62
|
-
"@modern-js/module-tools": "0.0.0-next-
|
|
63
|
-
"@modern-js/runtime": "0.0.0-next-
|
|
64
|
-
"@modern-js/server-core": "0.0.0-next-
|
|
65
|
-
"@modern-js/
|
|
66
|
-
"@modern-js/builder-
|
|
67
|
-
"@modern-js/
|
|
68
|
-
"@modern-js/builder-
|
|
69
|
-
"@scripts/build": "0.0.0-next-
|
|
59
|
+
"@modern-js/app-tools": "0.0.0-next-20231106082800",
|
|
60
|
+
"@modern-js/core": "0.0.0-next-20231106082800",
|
|
61
|
+
"@modern-js/module-tools": "0.0.0-next-20231106082800",
|
|
62
|
+
"@modern-js/runtime": "0.0.0-next-20231106082800",
|
|
63
|
+
"@modern-js/server-core": "0.0.0-next-20231106082800",
|
|
64
|
+
"@modern-js/types": "0.0.0-next-20231106082800",
|
|
65
|
+
"@modern-js/builder-webpack-provider": "0.0.0-next-20231106082800",
|
|
66
|
+
"@modern-js/builder-rspack-provider": "0.0.0-next-20231106082800",
|
|
67
|
+
"@modern-js/builder-shared": "0.0.0-next-20231106082800",
|
|
68
|
+
"@scripts/build": "0.0.0-next-20231106082800"
|
|
70
69
|
},
|
|
71
70
|
"peerDependencies": {
|
|
72
|
-
"@modern-js/runtime": "0.0.0-next-
|
|
71
|
+
"@modern-js/runtime": "0.0.0-next-20231106082800"
|
|
73
72
|
},
|
|
74
73
|
"peerDependenciesMeta": {
|
|
75
74
|
"@modern-js/runtime": {
|
package/dist/runtime.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
package/dist/runtime.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var import_devtools_mount = require("@modern-js/devtools-mount");
|
|
3
|
-
var import_ufo = require("ufo");
|
|
4
|
-
try {
|
|
5
|
-
const opts = (0, import_ufo.parseQuery)(__resourceQuery);
|
|
6
|
-
(0, import_devtools_mount.mountDevTools)(opts);
|
|
7
|
-
} catch (err) {
|
|
8
|
-
const e = new Error("Failed to execute mount point of DevTools.");
|
|
9
|
-
e.cause = err;
|
|
10
|
-
console.error(e);
|
|
11
|
-
}
|