-
Notifications
You must be signed in to change notification settings - Fork 2.1k
feat(examples): add dev live reload task to example-with-angular
#10716
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(examples): add dev live reload task to example-with-angular
#10716
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
@chris-dura is attempting to deploy a commit to the Vercel Team on Vercel. A member of the Team first needs to authorize it. |
|
@chris-dura None of us on the team know Angular, so we're happy to accept community wisdom here. Do you want to close or turn the draft to an open PR? |
|
Will close here due to staleness. Let me know if you'd like to revisit! |
Description
I think it's a conventional development workflow to launch both the Angular app (ie,
webanddocs) and watch for changes in theuimodule. However, the current example'swatchandstarttasks (which frontng buildandng serve) don't seem to work "as expected".By default,
persistenttasks in Turborepo run at the same time; however, theng servein the web app will fail (and doesn't "self-heal"), because theng buildcommand in the ui package hasn't finished generating thedist.I first tried all the various configurations I could find to try and get the web app
ng serveto properly recognize changes in the@repo/uipackage and "self-heal" after the first run, for example, usingpathconfigurations intsconfig.json, etc, but nothing seemed to work (I may be not doing it properly, as I'm not super-familiar with Angular)I then tried some turbo.json configs, trying to use
interruptible,turbo watchetc. However, there was still a problem with the first run failing.sleepbefore EVERYdevtask that has dependencies would soon run out of runway, so really, properly recognizing changes and "restarting" the task would be the appropriate way of doing it :/angular.jsonto re-establish the "self-healing" of theng servethat we'd see in a non-Turborepo setupTesting Instructions
Running
turbo run devorturbo run dev --filter=...@repo/uiwillng build --watchthe@repo/uilibrary, and serve thewebapp atlocalhost:4200.Make changes to the
@repo/uilibrary and the app should rebuild and display the changes.