vscode runs front-end code


vscode can install a static web server Live Server to run front-end code for easy debugging. The latest Live Server has supported php dynamic pages.
The installation method is to click the fifth icon on the left to open the "Extension" page, enter Live Server in the text box, click the first search result, click Install on the right page, and wait for the installation to complete.
The operation method is to select the project and click the Go live button in the toolbar at the bottom of the screen. Click again to stop running the server.
Live Server has some default configuration options that users can modify. Click File -> Preferences -> Settings, and find Live Server Config on the right page, which lists the configuration properties of this plugin. Copy it to the right, modify the property value, and click Save. For example, to modify the default port, you can copy the following code to the user settings on the right side of the page.
 
1
"liveServer.settings.port" : 5501
 
Click Save, and the default port is 5500 to 5501.
For the meaning of other settings, find the documentation of the plugin.
Note that all settings in VSCode are configured via json formatted data. Users can find the corresponding key value, modify its value, and then modify the configuration properties.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325902483&siteId=291194637