@deot/dev-dever 2.6.0 → 2.7.0

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/index.cjs CHANGED
@@ -76,6 +76,9 @@ const get = () => {
76
76
  const dirname = path__namespace.dirname(node_url.fileURLToPath((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.src || new URL('index.cjs', document.baseURI).href))));
77
77
  const run = (options) => devShared.Utils.autoCatch(async () => {
78
78
  const locals = devShared.Locals.impl();
79
+ options.packageName = devShared.Locals.getRealPackageName(options.packageName);
80
+ options.vuePackage = devShared.Locals.getRealPackageName(options.vuePackage);
81
+ options.reactPackage = devShared.Locals.getRealPackageName(options.reactPackage);
79
82
  if (typeof options.dryRun === "undefined") {
80
83
  options.dryRun = process.env.NODE_ENV === "UNIT";
81
84
  }
@@ -133,10 +136,12 @@ const run = (options) => devShared.Utils.autoCatch(async () => {
133
136
  }
134
137
  process.env.DEV_OPTIONS = encodeURIComponent(JSON.stringify(devOptions));
135
138
  const server = await vite.createServer(options$);
136
- const $server = await server.listen();
137
- const { local = [], network = [] } = $server.resolvedUrls || {};
138
- const url = network[0] || local[0] || `http://localhost:${$server.config.server.port}`;
139
+ await server.listen();
140
+ const { local = [], network = [] } = server.resolvedUrls || {};
141
+ const url = network[0] || local[0] || `http://localhost:${server.config.server.port}`;
139
142
  entries.forEach((item) => devShared.Logger.log(` > ${item}: ${chalk.cyan(`${url}${item}.html`)}`));
143
+ server.printUrls();
144
+ server.bindCLIShortcuts({ print: true });
140
145
  });
141
146
 
142
147
  exports.run = run;
package/dist/index.js CHANGED
@@ -51,6 +51,9 @@ const get = () => {
51
51
  const dirname = path.dirname(fileURLToPath(import.meta.url));
52
52
  const run = (options) => Utils.autoCatch(async () => {
53
53
  const locals = Locals.impl();
54
+ options.packageName = Locals.getRealPackageName(options.packageName);
55
+ options.vuePackage = Locals.getRealPackageName(options.vuePackage);
56
+ options.reactPackage = Locals.getRealPackageName(options.reactPackage);
54
57
  if (typeof options.dryRun === "undefined") {
55
58
  options.dryRun = process.env.NODE_ENV === "UNIT";
56
59
  }
@@ -108,10 +111,12 @@ const run = (options) => Utils.autoCatch(async () => {
108
111
  }
109
112
  process.env.DEV_OPTIONS = encodeURIComponent(JSON.stringify(devOptions));
110
113
  const server = await createServer(options$);
111
- const $server = await server.listen();
112
- const { local = [], network = [] } = $server.resolvedUrls || {};
113
- const url = network[0] || local[0] || `http://localhost:${$server.config.server.port}`;
114
+ await server.listen();
115
+ const { local = [], network = [] } = server.resolvedUrls || {};
116
+ const url = network[0] || local[0] || `http://localhost:${server.config.server.port}`;
114
117
  entries.forEach((item) => Logger.log(` > ${item}: ${chalk.cyan(`${url}${item}.html`)}`));
118
+ server.printUrls();
119
+ server.bindCLIShortcuts({ print: true });
115
120
  });
116
121
 
117
122
  export { run };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deot/dev-dever",
3
- "version": "2.6.0",
3
+ "version": "2.7.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -21,14 +21,14 @@
21
21
  "access": "public"
22
22
  },
23
23
  "dependencies": {
24
- "@deot/dev-react": "^2.6.0",
25
- "@deot/dev-shared": "^2.6.0",
26
- "@deot/dev-vue": "^2.6.0",
24
+ "@deot/dev-react": "^2.7.0",
25
+ "@deot/dev-shared": "^2.7.0",
26
+ "@deot/dev-vue": "^2.7.0",
27
27
  "ejs": "^3.1.9",
28
- "vite": "^4.5.0"
28
+ "vite": "^5.0.5"
29
29
  },
30
30
  "devDependencies": {
31
- "@deot/dev-test": "^2.6.0",
31
+ "@deot/dev-test": "^2.7.0",
32
32
  "cross-env": "^7.0.3"
33
33
  }
34
34
  }