You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using angular with laravel, so I can not directly use ng serve to test my site, but after I upgrade angular to 8.1.0, I found that ng build --watch can not work, before the upgrade, it's fine.
🔬 Minimal Reproduction
steps to reproduction:
cd webroot folder
ng new test-app
npm add -D holderjs
add "node_modules/holderjs/holder.min.js" to angular.json's scripts part
change base tag in index.html to something like /test-app/dist/test-app/, and it must be the correct folder
ng build --watch
open url like https://localhost/test-app/dist/test-app then, you will find that holderjs can not be loaded, because, there is no window object exists when running the holder.min.js
but if I use ng serve, then holderjs will NOT throw any error. this only happens when I'm using --watch
not only this happens to holder.js, for my project, I'm using holderjs and fancybox, they all have this problem. so I believe this is a bug in @angular/cli
🐞 Bug report
Command (mark with an
x
)Is this a regression?
@angular/cli<8.1.0 are good, so I think it is
Description
I'm using angular with laravel, so I can not directly use ng serve to test my site, but after I upgrade angular to 8.1.0, I found that
ng build --watch
can not work, before the upgrade, it's fine.🔬 Minimal Reproduction
steps to reproduction:
webroot folder
"node_modules/holderjs/holder.min.js"
to angular.json'sscripts
partbase
tag inindex.html
to something like/test-app/dist/test-app/
, and it must be the correct folderhttps://localhost/test-app/dist/test-app
then, you will find that holderjs can not be loaded, because, there is no window object exists when running theholder.min.js
but if I use ng serve, then holderjs will NOT throw any error. this only happens when I'm using
--watch
🌍 Your Environment
Anything else relevant?
no
The text was updated successfully, but these errors were encountered: