@woodsportal/hubspot-kit 1.0.43-dev.0 → 1.0.43-dev.1
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@woodsportal/hubspot-kit",
|
|
3
|
-
"version": "1.0.43-dev.
|
|
3
|
+
"version": "1.0.43-dev.1",
|
|
4
4
|
"packageManager": "pnpm@10.12.1",
|
|
5
5
|
"description": "WoodsCLI — HubSpot CMS dev kit by WoodsPortal. wp CLI, Vite presets, module-config overlay, and theme/module build pipelines.",
|
|
6
6
|
"type": "module",
|
|
@@ -133,6 +133,19 @@ function copyCdnArtifacts(sourceDir, targetDir) {
|
|
|
133
133
|
}
|
|
134
134
|
const src = join(sourceDir, entry)
|
|
135
135
|
const dest = join(targetDir, entry)
|
|
136
|
+
// Merge lazy chunks instead of replacing the whole directory. HubSpot modules
|
|
137
|
+
// pin app.{buildId}.js; wiping older chunks/ breaks CMS preview and lazy routes
|
|
138
|
+
// for any portal still on a previous build id (app files are kept; chunks were not).
|
|
139
|
+
if (entry === 'chunks' && existsSync(dest)) {
|
|
140
|
+
mkdirSync(dest, { recursive: true })
|
|
141
|
+
for (const chunk of readdirSync(src)) {
|
|
142
|
+
if (chunk.endsWith('.map')) {
|
|
143
|
+
fail(`Refusing to publish source map: chunks/${chunk}`)
|
|
144
|
+
}
|
|
145
|
+
cpSync(join(src, chunk), join(dest, chunk), { recursive: true })
|
|
146
|
+
}
|
|
147
|
+
continue
|
|
148
|
+
}
|
|
136
149
|
rmSync(dest, { recursive: true, force: true })
|
|
137
150
|
cpSync(src, dest, { recursive: true })
|
|
138
151
|
}
|