The current URL is mapped to a static server URL

Background: I wrote an index.html and opened it directly in a browser from the development software. The address will be like http://localhost:63343/index.html , but this is only accessible to developers. If another person also I want to see the effect of your writing, how to do it?

  1. Open the terminal and enter the project file
  2. Install anywhere: npm install anywhere -g
  3. Check the current port usage: anywhere --help
  4. Specify a port to open: anywhere -p 80  
  5. Finally, enter the URL in the browser to preview

 

Guess you like

Origin blog.csdn.net/csdnyp/article/details/124887672
URL
URL
URL
URL