Integrating heavy dynamic e-commerce frontends (like Angular-shop) with lightweight multi-domain CMS systems requires strict compile-time workflows to avoid synchronization errors. This log documents our Angular storefront compilation and integration workflow.
Decoupled Compilation and Asset Copying
All modifications and visual updates to the storefront must be made in the dedicated Angular repository (angular-shop) rather than editing compiled assets directly inside the CMS project. Running a production build with disabled telemetry prompts yields optimized JS/CSS bundles:
NG_CLI_ANALYTICS=false ng build --configuration production
The compiled output artifacts (contents of the dist/ folder) are then programmatically copied into the CMS public directory at public/astoreforbeauty/angular-shop/.
Integration and Cache Invalidation
By keeping storefront development strictly separate, we prevent asset drift. Express routes intercepting shop requests serve index.html directly from this folder, ensuring the latest features (cart state, Stripe checkout integrations) remain in perfect sync with backend updates.
