The inception of ESLint ↦
We love a good origin story around here! In this post, Nicholas C. Zakas, the author and maintainer of ESLint, shares its backstory — specifically, the series of events that eventually lead to ESLint’s creation.
After digging around in the build system at Box, I found there was actually a PHP linter running in addition to the makeshift JavaScript linter. The PHP linter, however, was a lot more involved that the JavaScript one. Instead of using regular expressions, the PHP linter parsed the code into an abstract syntax tree (AST) and then inspected the AST for the patterns to report.
I was probably shaking my head “yes” as I read through that code. Immediately I realized that this was exactly what I needed to do for JavaScript. If only there was some way to parse JavaScript into an AST and then inspect the AST for problems.
Also, if you want to support Nicholas’s work to maintain ESLint, checkout his Patreon.
Discussion
Sign in or Join to comment or subscribe