I have a angular 4 app with angular-cli aot, and I build the prod version on azure web app
I noticed that on some pages styles bundle try to find it by relative path
As result I see next error in console:
GET http://example.com/en/styles.b0bf326c21a7f4ee7e7f.bundle.css net::ERR_ABORTED
in the html I see that css doesn't start from "/":
<link href="styles.b0bf326c21a7f4ee7e7f.bundle.css" rel="stylesheet">
How I can fix that?
Thanks
Found the solution here
--deploy-url (aliases: -d)
URL where files will be deployed.
node ./node_modules/@angular/cli/bin/ng build --prod --deploy-url /
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With