@moneko/core 4.13.2 → 4.13.3
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/lib/build-dev.mjs +2 -2
- package/lib/build.mjs +2 -2
- package/lib/dev/config.mjs +1 -1
- package/package.json +3 -3
package/lib/build-dev.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{relative as o,sep as r}from"node:path";import
|
|
2
|
-
`):(n(
|
|
1
|
+
import{relative as o,sep as r}from"node:path";import t from"node:process";import{analyzeBundleSize as e,completedInfo as m,ink as i,println as a,progressBar as n}from"@moneko/utils";import s from"webpack";import l from"./commom/log.mjs";import p from"./commom/paths.mjs";import{CONFIG as c}from"./config.mjs";import{createDevelopmentConfiguration as g}from"./create-development-configuration.mjs";let u=await g({});if(c.bar){let o=c.bar,r=o.name||"Build";u.plugins.push(new s.ProgressPlugin({handler(e,m,...i){let a=i.length?`[${m}] ${i.join(" ")}`:" ";o.quiet?t.stdout.write(`${a}
|
|
2
|
+
`):(n(e||0,1,{msg:a,name:r,barColor:o.barColor,nameColor:o.nameColor,barBgColor:o.barBgColor,msgColor:o.msgColor}),1===e&&t.stdout.write("\r\x1b[2K"))}}))}let f=s(u);async function h(){let t=await new Promise((o,r)=>{f?.run((t,e)=>{t&&r(t),e?o(e):r(Error("编译过程中没有生成统计信息"))})});(t.hasErrors()||t.hasWarnings())&&function(o){let{warnings:r,errors:t}=o.compilation,e=[];r.forEach(o=>{o.message.includes("Conflicting order between css ")?e.push(o.message):a(i(o.message,"178"))}),e.length&&l(e.join("\n")),t.forEach(o=>{a(i(o.message,"red"))})}(t),await new Promise(n=>{t.compilation.compiler.cache.shutdown(s=>{s&&a(i(s.toString(),"red")),e(t.compilation.outputOptions.path,["\\.js$"]),m(~~((t.endTime-t.startTime)/10)/100,o(p.programPath,t.compilation.outputOptions.path).replaceAll(r,"/")),n()})})}await h();
|
package/lib/build.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{relative as o,sep as r}from"node:path";import m from"node:process";import{analyzeBundleSize as e,completedInfo as t,ink as i,println as n,progressBar as s}from"@moneko/utils";import a from"webpack";import{merge as l}from"webpack-merge";import p from"./build/common.mjs";import u from"./commom/log.mjs";import g from"./commom/paths.mjs";import{DonePlugin as c}from"./plugin/done.mjs";import
|
|
2
|
-
`):(s(e||0,1,{msg:n,name:r,barColor:o.barColor,nameColor:o.nameColor,barBgColor:o.barBgColor,msgColor:o.msgColor}),1===e&&m.stdout.write("\r\x1b[2K"))}}))}let b=a(w);if(!b)throw Error("无法创建编译器");async function j(){let m=await new Promise((o,r)=>{b?.run((m,e)=>{m&&r(m),e?o(e):r(Error("编译过程中没有生成统计信息"))})});(m.hasErrors()||m.hasWarnings())&&function(o){let{warnings:r,errors:m}=o.compilation,e=[];r.forEach(o=>{o.message.includes("Conflicting order between css
|
|
1
|
+
import{relative as o,sep as r}from"node:path";import m from"node:process";import{analyzeBundleSize as e,completedInfo as t,ink as i,println as n,progressBar as s}from"@moneko/utils";import a from"webpack";import{merge as l}from"webpack-merge";import p from"./build/common.mjs";import u from"./commom/log.mjs";import g from"./commom/paths.mjs";import{DonePlugin as c}from"./plugin/done.mjs";import f from"./utils/seo.mjs";import{CONFIG as d}from"./config.mjs";import h from"./module.config.mjs";let w=l(p,{module:h(!1),plugins:[]});if(d.done&&w.plugins.push(new c({done:d.done})),d.bar){let o=d.bar,r=o.name||"Build";w.plugins.push(new a.ProgressPlugin({handler(e,t,...i){let n=i.length?`[${t}] ${i.join(" ")}`:" ";o.quiet?m.stdout.write(`${n}
|
|
2
|
+
`):(s(e||0,1,{msg:n,name:r,barColor:o.barColor,nameColor:o.nameColor,barBgColor:o.barBgColor,msgColor:o.msgColor}),1===e&&m.stdout.write("\r\x1b[2K"))}}))}let b=a(w);if(!b)throw Error("无法创建编译器");async function j(){let m=await new Promise((o,r)=>{b?.run((m,e)=>{m&&r(m),e?o(e):r(Error("编译过程中没有生成统计信息"))})});(m.hasErrors()||m.hasWarnings())&&function(o){let{warnings:r,errors:m}=o.compilation,e=[];r.forEach(o=>{o.message.includes("Conflicting order between css ")?e.push(o.message):n(i(o.message,"178"))}),e.length&&u(e.join("\n")),m.forEach(o=>{n(i(o.message,"red"))})}(m),await new Promise(s=>{m.compilation.compiler.cache.shutdown(a=>{a&&n(i(a.toString(),"red")),e(m.compilation.outputOptions.path,["\\.js$"]),t(~~((m.endTime-m.startTime)/10)/100,o(g.programPath,m.compilation.outputOptions.path).replaceAll(r,"/")),s()})}),d.seo&&f()}await j();
|
package/lib/dev/config.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import{ink as e,println as o,termClear as r}from"@moneko/utils";import{hostHelp as m}from"../commom/host.mjs";import t from"../commom/log.mjs";import{getIPv4 as s,getPort as n}from"../commom/net.mjs";import i from"../commom/print-log.mjs";import{releasePortExclusion as l}from"../commom/release-port-exclusion.mjs";import{CONFIG as a}from"../config.mjs";import{packageJson as p}from"../process-env.mjs";let c=a.devServer.port||3e3;export const PORT=await n(c);l(PORT),a.devServer.port=PORT;let g="/"===a.basename?"":a.basename,d=c!==PORT&&e(`Port ${e(`${c}`,"yellow")} is in use, trying ${e(`${PORT}`,"green")} instead.
|
|
2
|
-
`,"245");export function getServerAddress(e){return`${a.devServer.https?"https":"http"}://${"local"===e?a.devServer.host:s()}:${PORT}${g}`}let v=e("Your application is running here:","245"),f=[e(` ${p.name} `,"253",{bg:"130"}),e(` v${p.version} `,"130",{bg:"255"}),e(" • [","245"),e(p.description,"130"),e("]","245")].join("");export function devLog(s,n){r(3);let l=(n?.endTime??0)-(n?.startTime??0);if(o(f,!0),o("",!0),o(v,!0),o("",!0),i("Local",getServerAddress("local"),{timestamp:!1,labelBackgroundColor:"blue",labelLen:9}),i("Network",getServerAddress("net"),{timestamp:!1,labelBackgroundColor:"29"}),o("",!0),o(e(`Compiled successfully in ${e(`${l}ms`,"green")}`,"245"),!0),o("",!0),d&&o(d),m(a.devServer.host),n){let e=[];n.compilation.warnings.forEach(r=>{r.message.includes("Conflicting order between css
|
|
2
|
+
`,"245");export function getServerAddress(e){return`${a.devServer.https?"https":"http"}://${"local"===e?a.devServer.host:s()}:${PORT}${g}`}let v=e("Your application is running here:","245"),f=[e(` ${p.name} `,"253",{bg:"130"}),e(` v${p.version} `,"130",{bg:"255"}),e(" • [","245"),e(p.description,"130"),e("]","245")].join("");export function devLog(s,n){r(3);let l=(n?.endTime??0)-(n?.startTime??0);if(o(f,!0),o("",!0),o(v,!0),o("",!0),i("Local",getServerAddress("local"),{timestamp:!1,labelBackgroundColor:"blue",labelLen:9}),i("Network",getServerAddress("net"),{timestamp:!1,labelBackgroundColor:"29"}),o("",!0),o(e(`Compiled successfully in ${e(`${l}ms`,"green")}`,"245"),!0),o("",!0),d&&o(d),m(a.devServer.host),n){let e=[];n.compilation.warnings.forEach(r=>{r.message.includes("Conflicting order between css ")?e.push(r.message):o(r.message)}),n.compilation.errors.forEach(e=>{o(e.message)}),e.length&&t(e.join("\n"))}s&&o(s.message)}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@moneko/core",
|
|
3
|
-
"version": "4.13.
|
|
3
|
+
"version": "4.13.3",
|
|
4
4
|
"description": "@moneko/core",
|
|
5
5
|
"main": "lib/index.mjs",
|
|
6
6
|
"type": "module",
|
|
@@ -142,7 +142,7 @@
|
|
|
142
142
|
"@moneko/utils": "0.3.5",
|
|
143
143
|
"@swc/core": "1.16.2",
|
|
144
144
|
"@tailwindcss/webpack": "4.3.3",
|
|
145
|
-
"browserslist": "4.
|
|
145
|
+
"browserslist": "4.29.0",
|
|
146
146
|
"core-js": "3.50.0",
|
|
147
147
|
"core-js-compat": "3.50.0",
|
|
148
148
|
"husky": "9.1.7",
|
|
@@ -159,7 +159,7 @@
|
|
|
159
159
|
"devDependencies": {
|
|
160
160
|
"@modelcontextprotocol/sdk": "1.30.0",
|
|
161
161
|
"@types/node": "26.5.1",
|
|
162
|
-
"zod": "4.6.
|
|
162
|
+
"zod": "4.6.5"
|
|
163
163
|
},
|
|
164
164
|
"publishConfig": {
|
|
165
165
|
"access": "public",
|