Use custom devserver
Is this a bug report or a feature request?
- [ ] Bug Report
- [X] Feature Request
Please provide the steps to reproduce the issue [Bug Report only]
No response
Please provide the expected behavior vs the actual behavior you encountered [Bug Report only]
No response
Please provide a screenshot if possible [Bug Report only]
No response
Please provide the exception or error you saw [Bug Report only]
No response
Is this a browser-specific issue? If so, please specify the device, browser, and version. [Bug Report only]
No response
Description [Feature Request only]
I want to use a customized express as devserver, in which I can customize some special configurations, such as middleware, routing, etc.
In fact, I am now trying to make a front-end and back-end isomorphic project, which has been initially set up, using angular + nestjs.
Proposed solution [Feature Request only]
I don't want to stop there and try to use express instead of ng's devserver.
I'm not familiar with the code of devserver. I guess there is a method similar to Adapter or Factory to load express, but after looking at the source code of cli, it seems that it is coupled. I can't extract the code of the server creation part separately. , I also need to rewrite the entire HMR logic.
Based on the current situation, I want to try to enable ng's devserver to load an external express example first, and then explore the rest. (Perhaps there is already a mature solution that I don’t know about?)
what should I do?
Alternatives considered [Feature Request only]
I don't want to start two servers during the development process, so I currently use the cruder method of ng build --watch + webpack hmr to develop.