Estudando Angular 4 com typescipt e Angular CLI!
Este branch encapsula o refactory para usar o Módulo HttpClient introduzido no Angular 4.3. Alterações foram necessárias no múdulo principal da aplicação (providers) e nas classes RestaurantService, OrderService e ErrorHandler.
Este branch encapsula o refactory para o envio dos header atraves do HttpInterceptors. Alterações foram necessaŕias na classe OrderService e adição da classe interceptor AuthInterceptor
This project was generated with Angular CLI version 1.3.0.
Just run npm install
Run ng serve for a dev server. Navigate to http://localhost:4200/. The app will automatically reload if you change any of the source files. The local server use json-server library to setup a local REST api backend. Run node backend/dist/server at the root folder to start server.
While performing changes to the backend scripts, you can run nodemon --watch backend backend/dist/server.js and the server will reload automatically when you save the changes.
Run ng generate component component-name to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module.
ng serve or npm start
npm install -g json-server
node backend/dist/server
While performing changes to the backend scripts, you can run nodemon --watch backend backend/dist/server.js and the server will reload automatically when you save the changes.
Regex most used
/^(([^<>()\[\]\.,;:\s@\"]+(\.[^<>()\[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i
/^[0-9]*$/
Run ng build to build the project. The build artifacts will be stored in the dist/ directory. Use the -prod flag for a production build.
Run ng test to execute the unit tests via Karma.
Run ng e2e to execute the end-to-end tests via Protractor.
Before running the tests make sure you are serving the app via ng serve.
To get more help on the Angular CLI use ng help or go check out the Angular CLI README.
- Images by freepik.com.
- Project setup made during the HTML5 Study Group #67 meetup.
- Study Base: https://www.udemy.com/angular-pt/learn/v4/content