[英]I am getting "This site can’t be reached" on my browser when I am trying to run my angular project
I have installed Angular 13 on my system and I am not able to view its output on my chrome or in any browser.我已经在我的系统上安装了 Angular 13,但我无法在我的 chrome 或任何浏览器中查看它的 output。 Getting "This site can't be reached" error.出现“无法访问此站点”错误。 I am new to angular.我是 angular 的新手。 Can anyone help me with that one?谁能帮我解决这个问题?
Angular CLI: 13.3.9
Node: 14.15.0
Package Manager: npm 6.14.8
OS: Linux x64
Angular: 13.3.11
... animations, common, compiler, compiler-cli, core, forms
... platform-browser, platform-browser-dynamic, router
Package Version
---------------------------------------------------------
@angular-devkit/architect 0.1303.9
@angular-devkit/build-angular 13.3.9
@angular-devkit/core 13.3.9
@angular-devkit/schematics 13.3.9
@angular/cli 13.3.9
@schematics/angular 13.3.9
rxjs 7.5.6
typescript 4.6.4
And the package JSON file is this.而package JSON文件就是这个。
{
"name": "my-app",
"version": "0.0.0",
"scripts": {
"ng": "ng",
"start": "ng serve",
"build": "ng build",
"watch": "ng build --watch --configuration development",
"test": "ng test"
},
"private": true,
"dependencies": {
"@angular/animations": "~13.3.0",
"@angular/common": "~13.3.0",
"@angular/compiler": "~13.3.0",
"@angular/core": "~13.3.0",
"@angular/forms": "~13.3.0",
"@angular/platform-browser": "~13.3.0",
"@angular/platform-browser-dynamic": "~13.3.0",
"@angular/router": "~13.3.0",
"rxjs": "~7.5.0",
"tslib": "^2.3.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.3.9",
"@angular/cli": "~13.3.9",
"@angular/compiler-cli": "~13.3.0",
"@types/jasmine": "~3.10.0",
"@types/node": "^12.11.1",
"jasmine-core": "~4.0.0",
"karma": "~6.3.0",
"karma-chrome-launcher": "~3.1.0",
"karma-coverage": "~2.1.0",
"karma-jasmine": "~4.0.0",
"karma-jasmine-html-reporter": "~1.7.0",
"typescript": "~4.6.2"
}
}
And on the browser console, I am getting this warning.在浏览器控制台上,我收到了这个警告。
crbug/1173575, non-JS module files deprecated.
(anonymous) @ (index):6774
Maybe try to clear your history, cookies, and cache.也许尝试清除您的历史记录、cookies 和缓存。 Then delete the node_modules
folder and run yarn install
or npm install
and then run ng serve --open
.然后删除node_modules
文件夹并运行yarn install
或npm install
然后运行ng serve --open
。 The --open
option automatically opens your browser to http://localhost:4200/
. --open
选项会自动将您的浏览器打开到http://localhost:4200/
。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.