简体   繁体   中英

How to solve request error net::ERR_NAME_NOT_RESOLVED in WebStorm debugger?

I have created JavaScript debugger in WebStorm 2022.1 and backend requests fail during debugger running. Debugger URL is written as http://localhost:3000 and Angular CLI is running also on http://localhost:3000 . Do I need to add some additional configuration for requests?

GET http://backendURL/rights net::ERR_NAME_NOT_RESOLVED

The JavaScript debugger in Webstorm and the Angular CLI are conflicting on the same port(3000). You can change the port that the JavaScript debugger is running on by going to the "Run" menu in Webstorm and selecting "Edit Configurations" and change the "Debug port" to a different port(eg 3001) and re-run the debugger or you can change the port of Angular CLI by running ng serve --port=YOUR_PORT_NUMBER . Also, make sure that the backend URL is correct and that the server is running and accessible. If the issue persists, check the.network settings and make sure that there are no firewalls or other security measures blocking the connection.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM