logo

How to Contribute to Open-Source Projects ?

Date :2023-07-21
Read Time :2 min

how_to_contribute_to_open_source_projects

Contributing to open-source projects is a fantastic way to give back and grow as a developer. Drawing from my experiences with six projects in 2023, let’s explore valuable ways to contribute, with examples.

How to Contribute to Open-Source Projects ?

1. Finding a Project:

Start by finding an open-source project that aligns with your interests and skills. GitHub, GitLab, and other code hosting platforms are excellent places to discover active projects.

2. Understanding the Project and keeping track of activity:

Once you’ve selected a project, take some time to understand its codebase, structure, and the issues/roadmap it has. Familiarize yourself with the contribution guidelines and code of conduct for the project.

3. Ways of Contributing:

There are various ways to contribute to open-source projects. Let’s dive into them:

3.1. Adding a New Feature or Enhancement:

One of the best ways to contribute is to review the issues and choose one that you understand and can work on, following the specific rules of each repository. Alternatively, if you come across a missing feature that you need and others might benefit from, you can suggest and implement it.

For examples:

  1. I used “Uptime Kuma” a tool for monitoring the status of servers and services and sending notifications through various channels like Telegram. As the number of servers grew, the Telegram notifications became overwhelming. I suggested and implemented the idea of organizing servers into specific Topics, and after understanding the project’s internals, I worked on the feature, submitted a pull request, and it was merged, making it available for everyone. PR2716
  2. I recently started using the Vue-Sonner Alerts’ package, which is a nice and lightweight library. However, I noticed that the icon color was inconsistent with the UI because the styles were not customizable through the available properties. Therefore, I submitted a pull request that allows users to define separate variables for icon and text colors, supporting both dark and light modes. PR12

3.2. Improving Documentation or Adding Missing Examples:

Contributing to documentation or adding examples can be one of the easiest and most satisfying PRs. They are often merged quickly after the maintainer confirms their value. I’ve experienced this with Nuxt JS and NuxtLabs.

3.3. Fixing Bugs or Addressing Issues:

Fixing bugs, addressing issues, or resolving unexpected behavior can be found in the issues section. If the maintainer confirms it’s a valid bug, you can submit a PR to resolve it. Avoid issues with extensive discussions and ambiguity. (Note: I haven’t had personal experience with this type of contribution.)

3.4. Other Contributions: Comments, Reviews, and Discussions

Participating in discussions, reviewing PRs, suggesting improvements, and answering questions from others are valuable contributions. Even if they don’t appear in the contributors list, they are visible in your profile and are essential for project success.

Remember to keep the following in mind while contributing:

  1. Respect the project’s established code style and guidelines.
  2. Include Tests for Contributions: Writing tests for your contributions ensures that your code functions as intended and helps prevent regressions.
  3. Be patient and open to feedback from maintainers and other contributors.
  4. Stay Proactive and consistent. Consistency is key to becoming a valued contributor. Regularly engage with the project, submit new contributions, and actively participate in discussions.
  5. Learn from Rejections: If a contribution gets rejected, view it as an opportunity to learn and grow. Understand the reasons behind the rejection and use them to improve your skills and future contributions.

Contributing to open-source projects is a rewarding journey that empowers you to collaborate with a global community and make a positive impact. So, go ahead and dive into the world of open-source! 🚀✨

Related Articles