Skip to content

Commit de73b1c

Browse files
committed
fix(@schematics/angular): include default export for Express app
This update is required for Firebase functions compatibility. Closes #29488 (cherry picked from commit aa0ae45)
1 parent a13a49d commit de73b1c

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

packages/schematics/angular/ssr/files/application-builder-common-engine/server.ts.template

+2
Original file line numberDiff line numberDiff line change
@@ -63,3 +63,5 @@ if (isMainModule(import.meta.url)) {
6363
console.log(`Node Express server listening on http://localhost:${port}`);
6464
});
6565
}
66+
67+
export default app;

packages/schematics/angular/ssr/files/application-builder/server.ts.template

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,6 @@ if (isMainModule(import.meta.url)) {
6161
}
6262

6363
/**
64-
* The request handler used by the Angular CLI (dev-server and during build).
64+
* Request handler used by the Angular CLI (for dev-server and during build) or Firebase Cloud Functions.
6565
*/
6666
export const reqHandler = createNodeRequestHandler(app);

0 commit comments

Comments
 (0)