Issue
im creating an angular 13app using CLI i want to set a path to my app when i run it i got the following error :
Unknown option: '--base-href'
Unknown option: '/my-path/'
this is the command i run :
ng serve --base-href /my-path/
and
ng serve --base-href=/my-path/
and this are my dep :
"dependencies": {
"@angular/animations": "~13.2.0",
"@angular/common": "~13.2.0",
"@angular/compiler": "~13.2.0",
"@angular/core": "~13.2.0",
"@angular/forms": "~13.2.0",
"@angular/platform-browser": "~13.2.0",
"@angular/platform-browser-dynamic": "~13.2.0",
"@angular/router": "~13.2.0",
"@ng-bootstrap/ng-bootstrap": "^4.1.1",
"@reactivex/rxjs": "^6.6.7",
"angular-oauth2-oidc": "^13.0.1",
"bootstrap-icons": "^1.8.1",
"font-awesome": "^4.7.0",
"rxjs": "~7.5.0",
"tslib": "^2.3.0",
"zone.js": "~0.11.4"
},
any one have an idea about this isuue please and how i can set a path to my app in localhost ?
Regards
Solution
This option has been deprecated. You should set it in angular.json
, here :
"acme-project": {
[...]
"architect": {
"build": {
"options": {
"baseHref": "/my-path/",
Answered By - Arnaud Denoyelle
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.