Link Union is a web application designed for managing links from various sources. It allows users to save links along with a name, description, and tags. The application supports CRUD operations, user authentication (login and logout), user profiles, and contact forms. Additionally, it includes an about section, a list view for managing links, and the ability to print link lists as PDF files.
- Save links with name, description, and tags
- CRUD operations for managing links
- User authentication (login and logout)
- User profiles
- Contact form
- About section
- List view for managing links
- PDF export for link lists
To install Link Union locally, follow these steps:
- Clone the repository
- Navigate to the project directory
- Install dependencies
git clone <repository-url>
cd link-union
npm install
To run Link Union locally, use the following command: ng serve
Navigate to http://localhost:4200/
in your web browser to access the application.
- Build Your Angular Application: Before deploying to Netlify, you need to build your Angular application. Run the following command in your project directory:
ng build --prod
-
Create a Netlify Account: If you haven't already, sign up for a free account on Netlify.
-
Install the Netlify CLI (Command Line Interface):
npm install -g netlify-cli
- Login to Netlify: Run the following command and follow the prompts to log in to your Netlify account:
netlify login
- Deploy Your Application: Navigate to your project's dist folder (where your compiled application code resides) and run the following command:
cd dist/link-union # Adjust the directory if necessary
netlify deploy
(Follow the prompts to deploy your application. Netlify will provide you with a unique URL for your deployed application.)
- Configure Custom Domain (Optional): If you have a custom domain, you can configure it in your Netlify settings.
Link Union uses MongoDB Atlas as the database solution. Follow these steps to set up and use the database:
-
MongoDB Atlas: Set up a MongoDB Atlas cluster and configure the connection URL in your application.
-
Service Setup: The
userService
provided in the application handles CRUD operations for managing link data in the MongoDB Atlas database. The service uses the AngularHttpClient
module to interact with the database. -
Data Structure: The link data stored in the MongoDB Atlas database follows a specific structure. Each link object should have properties for
name
,description
,tags
, etc. Ensure that the data structure matches the model used by the application. -
CRUD Operations: The
userService
provides methods for performing CRUD operations on the link data in MongoDB Atlas. These methods include fetching all links, adding a new link, updating an existing link, and deleting a link. -
Integration with Components: Components within the application use the
userService
to interact with the MongoDB Atlas database. For example, the list view component fetches links from the service and displays them in the UI.
By following these steps, you can effectively manage link data using MongoDB Atlas within the Link Union application.
To run unit tests, execute: ng test
To run end-to-end tests, use: ng e2e
Contributions to Link Union are welcome! To contribute:
- Fork the repository.
- Create a new branch (
git checkout -b feature/my-feature
). - Make your changes and commit them (
git commit -am 'Add new feature'
). - Push to the branch (
git push origin feature/my-feature
). - Create a new pull request.
For more information on using Angular CLI, refer to the Angular CLI Overview and Command Reference page.