Three.js is a powerful cross-browser JavaScript library and application programming interface used to create and display animated 3D computer graphics in a web browser using WebGL. It’s a tool that I’ve been wanting to learn for some time but have never had the time or motivation to do. I figured when not kick off my 5-in-5 by doing a not too complicated project using three.js to familiarize myself with the framework and gain some experience.
For the project I wanted to mostly stick to the fundamentals so I could gain a general understanding of the tool. With this in mind I decided to create a globe application that also pulled data from a JSON file which contained general information on all the countries on the globe. It was a great way to for me to wrap my head around the framework’s globe and orbit functionality while also making the application dynamic by utilizing data. Of course I needed some sort of guidance as I couldn’t just approach it blindly so I referred to documentation and tutorials like this and this. My experience was very positive and I’m more than likely be using this library in future.