@moneko/core 3.26.12-beta.4 → 3.26.13

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/common.d.mts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { extname, join, resolve } from 'node:path';
2
- import type { Configuration, FileCacheOptions, ResolvePluginInstance } from 'webpack';
2
+ import type { Configuration, FileCacheOptions } from 'webpack';
3
3
  import paths, { config_files, CUSTOMCONFIG } from './commom/paths.mjs';
4
- import OverrideResolverPlugin, { type OverrideResolverOption } from './plugin/override-resolve.mjs';
4
+ import OverrideResolverPlugin from './plugin/override-resolve.mjs';
5
5
  import { isObject, node_modules, resolveProgram } from './utils/index.mjs';
6
6
  import { exampleModuleName } from './vm/example.mjs';
7
7
  import app from './vm/info.mjs';
@@ -11,8 +11,4 @@ import { isDev, isLibrary, NODE_ENV, PACKAGENAME, PACKAGEVERSION } from './proce
11
11
  export declare const outputConfig: Configuration['output'];
12
12
  declare let entryMap: Configuration['entry'];
13
13
  declare let cacheConfig: FileCacheOptions | false;
14
- declare const overrideResolve: {
15
- original: string;
16
- override: string;
17
- };
18
14
  export declare const commonConfig: Configuration;
package/lib/common.mjs CHANGED
@@ -1 +1 @@
1
- import{extname as e,join as t,resolve as o}from"node:path";import a,{config_files as n,CUSTOMCONFIG as s}from"./commom/paths.mjs";import i from"./plugin/override-resolve.mjs";import{isObject as l,node_modules as r,resolveProgram as m}from"./utils/index.mjs";import{exampleModuleName as p}from"./vm/example.mjs";import c from"./vm/info.mjs";import{CONFIG as u,PUBLICPATH as d}from"./config.mjs";import h from"./plugins.config.mjs";import{isDev as f,isLibrary as g,NODE_ENV as b,PACKAGENAME as y,PACKAGEVERSION as j}from"./process-env.mjs";export const outputConfig={path:m(g?"docs":"dist"),filename:"js/[name].bundle.js",chunkFilename:`js/[${f?"name":"contenthash"}].js`,assetModuleFilename:t=>{let o=e(t.filename||"").substring(1);return`assets/${o}/[name][hash][ext]`},library:{name:`${c.projectName}`,type:"umd",umdNamedDefine:!0},globalObject:"window",chunkLoadingGlobal:`webpackJsonp_${y}`,pathinfo:f,clean:!0,publicPath:d,asyncChunks:!0,charset:!0,iife:!0,crossOriginLoading:"anonymous",enabledWasmLoadingTypes:["fetch"],hotUpdateChunkFilename:"[id].[fullhash].hot.js",hotUpdateMainFilename:"[runtime].[fullhash].hot.json"};let v={main:[u.polyfill&&t(a.corePath,"./polyfills/replace-children.mjs"),r("@app/entry")].filter(Boolean)};u.entry&&("string"==typeof u.entry?v={main:[u.entry]}:Object.keys(u.entry)&&(v=Object.assign(v,u.entry))),"string"==typeof v.main&&(v.main=[v.main]),u.output&&("string"==typeof u.output?outputConfig.path=u.output:Object.keys(u.output)&&Object.assign(outputConfig,u.output));let C={type:"filesystem",allowCollectingMemory:!0,cacheDirectory:a.webpackCachePath,memoryCacheUnaffected:!0,name:`.${[s,b].filter(Boolean).join("-")}`,version:`${j}`,buildDependencies:{config:n}};!1===u.cache?C=!1:l(u.cache)&&(C=Object.assign(C,u.cache));let k=Object.assign({original:u.alias["@"],override:s&&m(s)},u.overrideResolve);export const commonConfig={name:"client",target:"web",devtool:u.devtool,entry:v,mode:f?"development":"production",stats:"errors-only",cache:C,snapshot:{immutablePaths:[/node_modules\/(?!(@app|@moneko)\/)/],managedPaths:[/^@app\/.+/,/^@moneko\/.+/],buildDependencies:{timestamp:!0,hash:!0}},infrastructureLogging:{level:"error"},externalsPresets:u.externalsPresets,plugins:h,node:{global:!1,__filename:!1,__dirname:!1},experiments:{topLevelAwait:!0,asyncWebAssembly:!0,cacheUnaffected:!0,layers:!0,lazyCompilation:u.lazyCompilation&&f&&{imports:!0,entries:!0,test:e=>{let t=e.nameForCondition();return!!(t&&(t.startsWith(r(p))||t.startsWith(r("@app/comment"))||t.startsWith(a.pagesPath)||t.startsWith(a.componentsPath)))}},buildHttp:l(u.buildHttp)?{allowedUris:[],lockfileLocation:o(a.httpCachePath,"http.lock"),cacheLocation:o(a.httpCachePath,"data"),upgrade:!0,...u.buildHttp}:u.buildHttp,backCompat:!0,futureDefaults:!0,css:!1,outputModule:!1},resolve:{extensions:[".mts",".mjs",".ts",".tsx",".js",".jsx",".json",".wasm"],alias:u.alias,modules:[a.nodeModules,a.pnpmNodeModules,a.denoNodeModules],mainFields:["browser","module","main"],mainFiles:["index"],plugins:[u.overrideResolve&&new i(k),...u.resolvePlugins].filter(Boolean),preferAbsolute:!0,cache:!0,fallback:{}},externals:u.externals,output:outputConfig};
1
+ import{extname as e,join as t,resolve as o}from"node:path";import s,{config_files as n,CUSTOMCONFIG as a}from"./commom/paths.mjs";import i from"./plugin/override-resolve.mjs";import{isObject as l,node_modules as r,resolveProgram as m}from"./utils/index.mjs";import{exampleModuleName as p}from"./vm/example.mjs";import c from"./vm/info.mjs";import{CONFIG as u,PUBLICPATH as d}from"./config.mjs";import h from"./plugins.config.mjs";import{isDev as f,isLibrary as g,NODE_ENV as b,PACKAGENAME as y,PACKAGEVERSION as j}from"./process-env.mjs";export const outputConfig={path:m(g?"docs":"dist"),filename:"js/[name].bundle.js",chunkFilename:`js/[${f?"name":"contenthash"}].js`,assetModuleFilename:t=>{let o=e(t.filename||"").substring(1);return`assets/${o}/[name][hash][ext]`},library:{name:`${c.projectName}`,type:"umd",umdNamedDefine:!0},globalObject:"window",chunkLoadingGlobal:`webpackJsonp_${y}`,pathinfo:f,clean:!0,publicPath:d,asyncChunks:!0,charset:!0,iife:!0,crossOriginLoading:"anonymous",enabledWasmLoadingTypes:["fetch"],hotUpdateChunkFilename:"[id].[fullhash].hot.js",hotUpdateMainFilename:"[runtime].[fullhash].hot.json"};let v={main:[u.polyfill&&t(s.corePath,"./polyfills/replace-children.mjs"),r("@app/entry")].filter(Boolean)};u.entry&&("string"==typeof u.entry?v={main:[u.entry]}:Object.keys(u.entry)&&(v=Object.assign(v,u.entry))),"string"==typeof v.main&&(v.main=[v.main]),u.output&&("string"==typeof u.output?outputConfig.path=u.output:Object.keys(u.output)&&Object.assign(outputConfig,u.output));let C={type:"filesystem",allowCollectingMemory:!0,cacheDirectory:s.webpackCachePath,memoryCacheUnaffected:!0,name:`.${[a,b].filter(Boolean).join("-")}`,version:`${j}`,buildDependencies:{config:n}};!1===u.cache?C=!1:l(u.cache)&&(C=Object.assign(C,u.cache));export const commonConfig={name:"client",target:"web",devtool:u.devtool,entry:v,mode:f?"development":"production",stats:"errors-only",cache:C,snapshot:{immutablePaths:[/node_modules\/(?!(@app|@moneko)\/)/],managedPaths:[/^@app\/.+/,/^@moneko\/.+/],buildDependencies:{timestamp:!0,hash:!0}},infrastructureLogging:{level:"error"},externalsPresets:u.externalsPresets,plugins:h,node:{global:!1,__filename:!1,__dirname:!1},experiments:{topLevelAwait:!0,asyncWebAssembly:!0,cacheUnaffected:!0,layers:!0,lazyCompilation:u.lazyCompilation&&f&&{imports:!0,entries:!0,test:e=>{let t=e.nameForCondition();return!!(t&&(t.startsWith(r(p))||t.startsWith(r("@app/comment"))||t.startsWith(s.pagesPath)||t.startsWith(s.componentsPath)))}},buildHttp:l(u.buildHttp)?{allowedUris:[],lockfileLocation:o(s.httpCachePath,"http.lock"),cacheLocation:o(s.httpCachePath,"data"),upgrade:!0,...u.buildHttp}:u.buildHttp,backCompat:!0,futureDefaults:!0,css:!1,outputModule:!1},resolve:{extensions:[".mts",".mjs",".ts",".tsx",".js",".jsx",".json",".wasm"],alias:u.alias,modules:[s.nodeModules,s.pnpmNodeModules,s.denoNodeModules],mainFields:["browser","module","main"],mainFiles:["index"],plugins:u.resolvePlugins,preferAbsolute:!0,cache:!0,fallback:{}},externals:u.externals,output:outputConfig};u.overrideResolve&&commonConfig.resolve.plugins.push(new i(Object.assign({original:u.alias["@"],override:a&&m(a)},u.overrideResolve)));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moneko/core",
3
- "version": "3.26.12-beta.4",
3
+ "version": "3.26.13",
4
4
  "description": "core",
5
5
  "main": "lib/index.mjs",
6
6
  "type": "module",