Skip to content

Getting Started

Project creation

Open a terminal and run the following command to create an Angular application:

Terminal window
npx -p @angular/cli@latest ng new angular-introduction-course --standalone=false --style=css --ssr=false --skip-tests=true

Open the project

πŸŽ“Instructions

  1. open Visual Studio Code.
  2. Click on the File menu and select Open Folder.
  3. Navigate to the practical-course folder and click on the Select Folder button.

Running the application

Angular CLI provides a command to serve the application locally.

πŸŽ“ Instructions

  1. Open a terminal in Visual Studio Code.
  2. Type the following command to start the application:
Terminal window
ng serve
  1. Open your browser and navigate to http://localhost:4200.
  2. You should see the following default boilerplate page:
A bird sitting on a nest of eggs.

Hot reload

Hot reload is a feature that allows you to see the changes you make in your code without having to manually refresh the page.

πŸŽ“ Instructions

  1. Open the src/app/app.component.html file.
  2. Replace the full content of the file with the following code:
app.component.html
<header>
<h1>Angular Practical course</h1>
</header>
  1. Go back to your browser to see the following page:
A bird sitting on a nest of eggs.

πŸ”Ž Want to learn more?