Closed
Description
Bug Report or Feature Request (mark with an x
)
- [x] bug report -> please search issues before submitting
- [ ] feature request
Versions.
Windows 10
@angular/cli: 1.3.2
node: 8.4.0
os: win32 x64
@angular/animations: 4.3.6
@angular/common: 4.3.6
@angular/compiler: 4.3.6
@angular/core: 4.3.6
@angular/forms: 4.3.6
@angular/http: 4.3.6
@angular/platform-browser: 4.3.6
@angular/platform-browser-dynamic: 4.3.6
@angular/router: 4.3.6
@angular/cli: 1.3.2
@angular/compiler-cli: 4.3.6
@angular/language-service: 4.3.6
Repro steps.
- Create a new, fresh app:
ng new test-app
- Create two modules to act as entry points
- In
main.ts
bootstrap both - Observe failure with
ng serve
(not statically analyzable?) - Comment one bootstrap out then
ng serve
again - after success, comment back in, now app has two bootstraps as intended
The log given by the failure.
$ ng serve --name=dev --port=8081
Tried to find bootstrap code, but could not. Specify either statically analyzable bootstrap code or pass in an entryModule to the plugins options.
Error: Tried to find bootstrap code, but could not. Specify either statically analyzable bootstrap code or pass in an entryModule to the plugins options.
Desired functionality.
ng serve
should be able to see that there are two bootstraps and handle that. This is super useful in multi-page applications to have a development environment, while supporting full separate apps in production.
Mention any other details that might be useful.
Could be related to #4624