Learning React: An Insight Into Tooling And Infrastructure
It had been more than half a decade since I dabbled with front-end development — I’m primarily a C++ platform developer who works in monolithic code. I’ve been running into React quite often as a library which can help build interactive websites easily. Curious to see what the fuss is all about, Jaikanth and I decided to explore this world by building a simple Tic-tac-toe application. Here’s the result:
https://karthikns.github.io/tictactoereact/
Learning React was nice. But there were two aspects in the tooling/infrastructure that stood out to me: collaborative coding and rapid speed of development/deployment.
Collaborative Coding
One of the major hurdles in working together was geography — Jaikanth lives in Bengaluru and I live in the Seattle ‘burbs. Another potential obstacle was that both of us have different backgrounds in software development.
Visual Studio Code has a wonderful plugin called Live Share which allows the host to share their running Visual Studio Code instance with their collaborator - the host and the guest can code together in the host’s instance. With that setup and a WhatsApp call, it felt like we were working in the same space.
After setting up the shared session, we decided to pair program. Each of us took on the roles ‘typist’ and ‘brain’ and switched roles every 10 minutes. This gave us a great way to learn from each others’ strengths, share ideas and sped up the learning.
Rapid Speed
What impressed me is that it was fairly straightforward to setup a pipeline such that making a change in a file and just saving it resulted in automatic code formatting, building and deploying the changes to a test server. The debugger in the browser works great but going the extra step to setup debugging via Visual Studio Code saved time.
Another aspect was the ease of deployment to GitHub pages — after a day’s coding, deploying to GitHib pages is fairly straightforward and involves running a simple command. From making a simple change to have it show up in GitHub pages is just a matter of minutes.
Here’s the repository: https://github.com/karthikns/tictactoereact
An icing on the cake would be setting up a CI/CD pipeline next and then automatic deployment when changes are pushed!