AngularでHello, World


セットアップ

$ curl -fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash -

nodejsをインストール

$ sudo apt install nodejs
$ node -v
$ npm -v

angularをインストール

$ sudo npm install -g @angular/cli
$ ng version

新プロジェクト作成

$ ng new hello-world
$ cd hello-world

起動

$ ng serve --host 0.0.0.0

ブラウザでアクセス

http://localhost:4200

テンプレートの編集

$ vi src/index.html
$ vi src/app/app.component.html