1

We have an Angular application with SSR that has some custom webpack configuration. We use NX to build it, with the executors @angular-builders/custom-webpack:browser and @angular-devkit/build-angular:server. It currently does SSR using CommonEngine, but we would like to migrate to the new AngularNodeAppEngine.

According to the NX website, @nx/angular:webpack-server is a "drop-in replacement for the @angular-devkit/build-angular:server builder provided by the Angular CLI" (and similarly for @nx/angular:webpack-browser). However, when running the generated main.js file, it immediately dies with the following Error:

Error: Angular app engine manifest is not set. Please ensure you are using the '@angular/build:application' builder to build your server application.
at getAngularAppEngineManifest (/xxx/dist/website/server/main.js:1:4955398)
at <instance_members_initializer> (/xxx/dist/website/server/main.js:1:4955554)
at new AngularAppEngine2 (/xxx/dist/website/server/main.js:1:4955252)
at <instance_members_initializer> (/xxx/dist/website/server/main.js:142:105945)
at new AngularNodeAppEngine (/xxx/dist/website/server/main.js:142:105901)
at 97432 (/xxx/dist/website/server/main.js:142:105897)
at __webpack_require__ (/xxx/dist/website/server/main.js:142:337379)
at /xxx/dist/website/server/main.js:142:339798
at Object.<anonymous> (/xxx/dist/website/server/main.js:142:340086)
at Module._compile (node:internal/modules/cjs/loader:1565:14)

Digging through the source code, it appears that @angular/build:application internally generates an AngularAppEngineManifest for the server, but apparently the NX builder doesn't.

Is this an unsupported feature? Upcoming? I haven't been able to find any documentation either way...

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.