Hacktoberfest and JavaScript

The month of October is known as the month of beer in many places of the world. As everything in the world of technology, we adapt events of the “humans” side and add it to the “exact” world. So Digital Ocean and Github have this event called Hacktoberfest. This event has the goal to push the Open Source world, were with 4 PR’s on any Github repository you win this amazing T-Shirt:

unnamed

But Lays, how JavaScript connects to Hacktoberfest? Last week, a friend of mine, Andre Garzia, made a HackDay meetup at Amora Labs office, where the event had the goal to develop add-ons for Mozilla Firefox. For me, is on this kind of meetups that I can get my hands dirty on JavaScript. And talking with my friends I discovered about Hacktoberfest. Truth to be told, I saw some friends on Facebook talking about it but didn’t give much attention.

 

22555627_1911135375568427_7289555979377638332_o
Me and my friends at Amora Labs Office

 

So I searched around some repositories and made the PR’s necessary to win the T-shirt. But on that meetup and the following rest of the weekend, I was diving deep on JavaScript and the MDN Apis for Addons development.

With the Containers feature coming up on the following Firefox versions, and my love for them since I started to use it on the Nightly version, I discovered some lacks on the addon that made my life hard on my management of Containers. Like every site I need to manually add it inside a container and assign it to it, so every time that I open that URL it opens inside the assigned container. The first thing that I thought, was to be able to save patterns. Like ‘*.google.com‘, always open in a Google container, instead of assign every Google service on the container. I think that we can do some hacks on it, so I worked in an addon with that purpose: Associate patterns to containers. With my bad judgment on what I wanted to do and poor knowledge of JavaScript, I was only able to get something working on the end of Sunday, after the start and drop around 4 projects… The folder of the project is called “lasttry“, and that paid off. I was able to make the prototype of my add-on with the base of the functionality that I want. On the end of that day I was really tired, and had 2 problems on my project:

1- The way that I was storing the information about what container was related to the pattern was being overrated on every new entry.

2- The event listener to monitor the URL request and redirect to the container is bad, and is opening a new tab for every request that the target needs to be loaded.

With that in mind, I added a documentation to the project, pushed to my Github and opened two issues related to the previous bugs. And associated with them the tag “Hacktoberfest” to see if I would receive PR’s for people that were participating in the program.

The name of the add-on is “You Shall Contain“:

Screenshot_20171029_183012

I was very surprised that on the next day of the publishing of this project on my Github I received a PR from a guy from Australia. His PR fixed the #1 issue. I was glad that I was able to review his work, give him feedback, and he fixed the small problems that I found on his submission. That was the first time that I received a PR on my personal projects.

So one problem down, one more to go… Unfortunately, I didn’t receive any PR for that issue and I don’t have enough knowledge to fix it.

I hope to be able to launch this addon and more improvements on the Firefox Store until the end of the year.

Last weekend was the first time in a while that I was able to program over the weekend instead of watching Netflix… Sometimes we need a change of environment to find our inner programmers spirit. And my conclusion is that my relationship with JS is: You can hate or you are too stubborn to give up because you can’t love it. =D

Published by lays147

A bit of everything.

One thought on “Hacktoberfest and JavaScript

Leave a comment