env:
Angular CLI
Visual stduio code
language: typescript
几个重要的组成结构:
modules–就像springboot AOP一样
Components (Model)->provide data for templates
Services(Controller)[business logic, http request, data storage]
Templates(View)
Data binding
Dependency injection
template->view
component->model(data)
service->controller
E2E folder: it for testing
Data binding commands:
one way binding means view to component or component to view
How to debug?
common way:
cmd, ng serve. open web browser, open dev tools. set cut points…
better way:
intall debugger for chrome.
add .vscode/launch.json
ng serve
press F5 in VSCODE, fresh the page…
Angular 从入门到实践