When you start debugging, the IDE takes the project root directory as the site root directory. How to tell her that the site root is the www subdirectory? It is necessary that the site opens not http: // localhost: 63342 / counter / www / index.html , but http: // localhost: 63342 / index.html .

Actually it

  • remove from URL /counter/www ? - Vasily Barbashev
  • @ Vasily Barbashev It then starts looking for index.html at the root of the project. 404 shorter - Vlad
  • So do not specify generally index.html . My duck is simply url http://localhost:8080/application/main . And everything worked fine when I last checked. There's also a plug-in he needs JB - Vasily Barbashev
  • @ Vasily Barbashev ide then searches for all files in the root directory of the GET project localhost: 63342 / counter / tpl / pagetwo.html 404 (Not Found). I’ve already covered everything, and I can’t understand jetbrains either - Vlad
  • from the very beginning, what goal do you want to get? - Vasily Barbashev

1 answer 1

The embedded web server in WebStorm always uses http://localhost:63342/<project root> as the project's web path. This is necessary in order to support the possibility of simultaneous work with several projects. It is not possible to http://localhost:63342 it so that you can simply use http://localhost:63342 (so that you can use URLs and requests that begin with / ). But you can edit the hosts so that you can use http://<project_name>:<port> . See https://youtrack.jetbrains.com/issue/WEB-8988#comment=27-577559