File tree 2 files changed +6
-1
lines changed
packages/angular_devkit/build_angular/src
2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -47,7 +47,7 @@ async function extract(): Promise<string[]> {
47
47
const bootstrapAppFnOrModule = bootstrapAppFn || AppServerModule ;
48
48
assert (
49
49
bootstrapAppFnOrModule ,
50
- `Neither an AppServerModule nor a bootstrapping function was exported from: ${ serverBundlePath } .` ,
50
+ `The file " ${ serverBundlePath } " does not have a default export for an AppServerModule or a bootstrapping function .` ,
51
51
) ;
52
52
53
53
const routes : string [ ] = [ ] ;
Original file line number Diff line number Diff line change 7
7
*/
8
8
9
9
import type { ApplicationRef , StaticProvider } from '@angular/core' ;
10
+ import assert from 'node:assert' ;
10
11
import { basename } from 'node:path' ;
11
12
import { loadEsmModule } from '../load-esm' ;
12
13
import { MainServerBundleExports , RenderUtilsServerBundleExports } from './main-bundle-exports' ;
@@ -73,6 +74,10 @@ export async function renderPage({
73
74
] ;
74
75
75
76
let html : string | undefined ;
77
+ assert (
78
+ bootstrapAppFnOrModule ,
79
+ 'The file "./main.server.mjs" does not have a default export for an AppServerModule or a bootstrapping function.' ,
80
+ ) ;
76
81
77
82
if ( isBootstrapFn ( bootstrapAppFnOrModule ) ) {
78
83
html = await renderApplication ( bootstrapAppFnOrModule , {
You can’t perform that action at this time.
0 commit comments