일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 | 31 |
Tags
- OP
- 나루토
- sid
- 容姿端麗な嘘
- Official髭男dism
- 강철의 연금술사
- 드라마
- NICO Touches the Walls
- Sword art online
- Mrs. GREEN APPLE
- THE ORAL CIGARETTES
- 귀멸의 칼날
- きみの名前
- 藤川千愛
- 文豪ストレイドッグス
- wms
- Django
- Kisses and Kills
- ラックライフ
- 소드 아트 온라인
- ED
- アポトーシス
- Lisa
- 명령어
- シド
- Git
- angular
- Yama
- 소드아트온라인
- ASCA
Archives
- Today
- Total
일본IT외노자생활
Angular 명령어 정리 본문
sudo npm install -g @angular/cli@latest
# mac인 경우
npm install -g @angular/cli@latest
# windows인 경우
앵귤러 cli 다운
ng new 프로젝트이름 --no-strict
프로젝트 생성
ng g c 컴포넌트이름
컴포넌트 생성
ng g c 컴포넌트이름 --skip-tests true
테스트파일 빼고 컴포넌트 생성
ng serve
로컬서버 기동
Could not find an NgModule. Use the '--skip-import' option to skip importing in NgModule.
에러 발생시
ng g c 컴포넌트이름 --skip-import
moudle이 없을때 moudle import를 생략하고 생성
npm install --save bootstrap@3
해당 프로젝트에서만 부트스트랩사용 => angular.json에서 styles 경로에 node_modules/bootstrap/dist/css/bootstrap.min.css 추가
ng g directive [디렉터리명]
# 또는
ng g d [디렉터리명]
디렉터리(폴더) 생성
ng serve를 입력했을때 오류발생
Node packages may not be installed. Try installing with 'npm install'.
Error: Could not find the '@angular-devkit/build-angular:dev-server' builder's node package.
npm install --save --legacy-peer-deps
입력
'IT > Angular' 카테고리의 다른 글
Angular 개념 정리 (0) | 2022.10.21 |
---|