My angular application is hosted in server in which the application url is http://xyz.domain.in (Example Url). Now I created sub directory inside it to host another application. But when i try to access the path like http://xyz.domain.in/subfolder , getting this in console.
Error: Cannot match any routes. URL Segment: 'subfolder'
Base href of the application in subfolder is
<base href="./subfolder">
How to accomplish this?
You have to specify the path of your subfolder when launching a build :
ng build --base-href=/subfolder/
do not need to mention the subfolder name, if you are depolying at subfoler you need to mention only href="./"
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