Shaping JavaScript Usage with ESLint

I have used ESLint for a long time, often extending the recommended rules from various plugins. I only read a rule’s documentation if I wasn’t sure why it was being flagged in the linter. Last month I read through and manually set 381 ESLint rules, reading the accompanying docs for each rule. I discovered that ESLint is more than enforcing community guidelines on code quality. It also helps to shape use of the language as a whole and through project specific rule usage. ...

May 23, 2019 · 7 min · Skyler Lemay

How to Manage Snapshots with ESLint

Snapshots are still an assertion, but can become broad ones. Favor specific assertions where workable. Jest Snapshots can be a valuable utility for monitoring code changes for UI components. They can also become a scourge if they become too large. The line between the two isn’t always clear. Snapshots don’t offer a clear mechanism to determining how large they are. This makes it easy to create large snapshots that are hard to diff. ...

March 18, 2019 · 3 min · Skyler Lemay

Iterating Quickly with GraphQL and Gatsby

Over the past month I have been adding features to the blog that I had put off for long enough. As I aim to write more, it was time to address some glaring omissions in my initial implementation. This included adding proper category and tag pages, post metadata, and other small features. Gatsby’s tight integration with GraphQL enabled quick iteration and development of these new features. Some features required as little as adding a utility field to a GraphQL query to implement. ...

March 11, 2019 · 7 min · Skyler Lemay

How to Manage Dependencies with Confidence

Managing dependencies is a core part of maintaining a project long term. Projects run the risk of decay if not maintained. The evolution of the environment around them can also introduce decay. Dependency management can be an intimidating and error prone process, if not approached with a plan. About a year ago, I went to update the dependencies for a full stack JavaScript application for the first time in over four months. Not knowing any better at the time, I ran npm update and updated all the server and client dependencies in one fell swoop. Looking back I shudder even thinking of that and what happened next. It took two to three hours to get beyond the red React error screen. It was another hour or two until I felt comfortable that everything was operational. ...

February 25, 2019 · 8 min · Skyler Lemay