- Welcome to the angular-interceptors project! This document provides instructions on how to set up, run, build, and test the codebase.
- This project was developed to study about angular interceptors and the power of this solution. I developed some important things for any application.
- This features are cool and importnat because without this we would need to:
- Add auth headers for each request in the entire application.
- Set loading for each request in the entire application.
- Do this simple logic in the entire application.
- To set default authorization headers in any request of my application, but I can exclude URLs from this if not necessary.
Before you begin, make sure you have the following software installed on your machine:
- Node.js (v18.17.1)
- npm (Node Package Manager)
- Angular CLI (v16.2.0)
-
Clone this repository to your local machine using the following command:
git clone <repository-url>
-
Navigate to the project directory:
cd angular-interceptors
- Install project dependencies using npm:
nvm i 18.17.1
nvm use
npm install
To run the application locally, use the following command: npm start
This will start the development server and launch the application in your default web browser. The app will automatically reload if you make any changes to the source code.
To build the application for production, execute the following command: npm run build
This will create a production-ready build of the application in the dist/
directory.
You can run tests using the following command: npm test
- For more advanced configurations, please refer to the official Angular documentation.