MCPcopy Create free account
hub / github.com/ScriptedAlchemy/tracedecay / createBundleConfig

Function createBundleConfig

dashboard/build.shared.mjs:88–119  ·  view source on GitHub ↗
({ entryName, entry, outDir, filename, alias = {} })

Source from the content-addressed store, hash-verified

86}
87
88function createBundleConfig({ entryName, entry, outDir, filename, alias = {} }) {
89 return {
90 root: dashboardRoot,
91 mode: "production",
92 source: {
93 entry: { [entryName]: rsbuildEntry(entry) },
94 define: { "process.env.NODE_ENV": JSON.stringify("production") },
95 },
96 resolve: {
97 alias,
98 extensions: EXTENSIONS,
99 },
100 output: {
101 distPath: { root: outDir, js: "." },
102 filename: { js: filename },
103 filenameHash: false,
104 cleanDistPath: true,
105 legalComments: "none",
106 minify: true,
107 },
108 performance: {
109 chunkSplit: { strategy: "all-in-one" },
110 printFileSize: false,
111 },
112 plugins: [pluginReact(), pluginTypeCheck()],
113 tools: {
114 rspack(config) {
115 applySingleBundleOutput(config);
116 },
117 },
118 };
119}
120
121export function createShellBuildConfig() {
122 return createBundleConfig({

Callers 2

createShellBuildConfigFunction · 0.85
createPluginBuildConfigFunction · 0.85

Calls 1

rsbuildEntryFunction · 0.85

Tested by

no test coverage detected