A finite state machine is a way to model state transitions in a system. The state pattern along with finite state machines encourage separation of concerns and loose coupling. Here's how to do it right!
Introduction In this post, I will show you some suggestions for structuring and organizing the front end of your app. Whenever I start working on a project, I like to scaffold it with some files and folders. The create-react-app cli is a good starting point. However, it only provides the bare minimum for what I would need to create a project. I will always need to add files and folders. However, if I start coding without some direction for how th
In Part I of this guide, I discussed designing the architecture for our fictitious app The Snap Gram. Next, we will take a deeper look at implementing routes in an Angular application. I consider this Angular's strong suit — creating single page applications. If you want to follow along with the examples, you can download the boilerplate code from Angular's Quickstart project. We will create an app with a few pages to demonstrate how routing wor
Imagine we are building the next big social app that lets users share content with other users. We will call our app The Snap Gram. This app will put all other apps out of business, so it is very important that we build it well. A flawed design can mean the difference in failure or success for our venture. All it takes is some big company to steal our idea and make it their own. In order to win the tech race, we have to be able to build and ship
If you are like me and have a background of using AngularJS, making the move to Angular may have come with some resistance. What I find to be the biggest difference of the two, and my biggest impedance, is Angular’s use of TypeScript. They have married themselves to TypeScript so strongly I do not even know where Angular ends and TypeScript begins. Another source of my contention is handling the responsibility compiling and module loading that c
I recently read the book Apprenticeship Patterns which advises programmers how to overcome the challenges that come with being and remaining self-taught and become better at what we do. Apprenticeship Patterns does not tell you how to write better code. What it does, is presents roadblocks you would encounter during your career with solutions to help you overcome them. An apprentice is someone that seeks to learn and get better at their craft. It
If you would like to publish a personal website, start a blog, or host any other static website, Jekyll and GitHub Pages offer a minimalistic solution. Other options for building a website are website builders like SquareSpace or content management systems like Wordpress. Both provide templates to design your site and require you pay for hosting. The other option is to build your own content management system. But if you are lazy like me, that i