DEV Community

Quinn Lashinsky
Quinn Lashinsky

Posted on

Making My First Open Source Contribution

Protesters gathering and raising their fists in a black power salute

For the past two days I had been checking Trello for a ticket that I thought I could complete. Finally, I found one! ...and I spent 10 minutes reasoning back and forth whether I could do it. I was paralyzed with fear. Could I accomplish this? Did I have the skills? Would my work be worthy enough to put into production?

I was extremely unsure if I could pull through. I mustered up the courage to ask the Team Lead if I could take the ticket. They gave me the go ahead.

I took a deep breath and I took the ticket.

The ticket involved adding clickable arrows to a pagination component. I had to make it so a user could click to go to the next or previous page. I had to take into account mobile and desktop styling, and I had to work with Chakra UI, a library I had no experience using.

The majority of the component was already built, but looking through the file only made me more confused than I had initially been.

After taking another deep breath I formulated a plan based on advice I had been given from the coding bootcamp I had attended, from a summer internship I had done, and hours of searching stack overflow. This was the process that helped me from beginning to end.

Write Down Ticket Requirements

I wrote down a list of every requirement I had to fulfill to complete the ticket. This let me see the exact amount of work I had to do, making it less cloudy what the end goal would look like.

Understand the File(s)

I took my time reading and examining the files. I attempted to get a high level overview of how the logic was affecting the view. Piecing together how each piece functioned to create the whole component gave me a quick look into how the component worked.

Change, Reload, Change, Reload

I took my time adjusting variables I thought might be related to fulfilling the requirements of the ticket. This helped me to get a deeper understanding of how the state, functions, and variables in the component work together.

Some tools I used beside directly changing code were

javascript console.log

and

javascript debugger

. These two were able to give me a good idea if I was getting back the values I expected and if my code was executing how I expected.

Note: If you become confused and want to clean the slate and remove all changes you made on unstaged files (files are not added or committed) run

git git checkout .

in your terminal and all the changes you made will be discarded. You can also discard changes in individual files using

git git checkout [FILE PATH HERE]

i.e.

git git checkout src/components/Pagination.js

Write Down Steps to Complete Ticket

After I had decent understanding of what the pagination component was doing, I decided to write out how I could possibly complete each task step by step.

All in all, it took me about 6 hours. I tried new things, combed at Chakra UI documentation and asked many questions. The thing I most struggled with were conventions used within the project. It's tempting to copy what other people are doing, but I tried to focus on why these decisions were made. I didn't want to emulate code as a default, because it could yield unintended side effects that could confuse me.

This was where having such a great team of volunteers and Team Leads helped. I started out unsure and wary of whether I could accomplish contributing to open source, but the above steps helped me to focus on the task at hand. I submitted my PR confident that the work I had done was worthy.

It was merged the next day and I made my first contribution to open source! πŸ₯³

Some open source projects will list issues with labels denoting them as good first source contributions, and I think if you feel comfortable enough with the technologies used or even a bit challenged, it may be worth it to take on the issue. I'm definitely still hesitant, but I know I'm gonna fight this feeling and make more contributions. Worst that happens is it doesn't get merged. But there will always be more open source to contribute to!

The project I was able to contribute to is Rebuild Black Business which just launched today!

It is an open source project to help black businesses survive as they navigate the age of COVID-19 and dealing with the aftermath of looting. Ultimately, it's an awesome site that provides resources to black business owners who need aid. You can even list yourself as an ally-- someone who is willing to be contacted and help black business owners!

I encourage those reading this post to take a look and contribute if they can. The entire team is volunteers and they put this together in about 2 weeks.

Top comments (0)