How to use Live Server?

To use Live Server in Visual Studio Code, follow these steps:

  1. Open Your Project: Make sure you have your project folder open in Visual Studio Code.

  2. Open an HTML File: Click on an HTML file in your project to open it in the editor.

  3. Start Live Server:

    • Option 1: Right-click on the HTML file in the editor and select "Open with Live Server".
    • Option 2: Click the "Go Live" button located in the bottom right corner of the Visual Studio Code window.
  4. View in Browser: A new browser tab will open, displaying your HTML file. Live Server will automatically refresh the page whenever you save changes to your file.

  5. Stop Live Server: To stop the server, click the "Port: [number]" button in the bottom right corner of Visual Studio Code, or close the browser tab.

That's it! You can now edit your HTML, CSS, or JavaScript files, and see the changes live in your browser.

0 Comments

no data
Be the first to share your comment!