Code Transformation and Linting with ASTs

Kent C. Dodds

Kent C. Dodds

Professional Trainer
3 hours, 28 minutes CC
Code Transformation and Linting with ASTs

Course Description

Learn Abstract Syntax Trees to help keep track of stylistic code changes, reveal logical problems, and spot domain-specific issues to prevent bugs from entering your codebase. By coding along with Kent in this course, you’ll learn: What Abstract Syntax Trees are, the tools available, and how to write custom ESLint rules, Babel plugins and Codemods with ASTs. This course is for experienced JavaScript developers who want to gain a deep understanding of Abstract Syntax Trees to solve frustrating problems with their codebase and improve their development experience writing JavaScript applications.

This course and others like it are available as part of our Frontend Masters video subscription.

Preview
Close

Course Details

Published: July 11, 2017

Learn Straight from the Experts Who Shape the Modern Web

Your Path to Senior Developer and Beyond
  • 200+ In-depth courses
  • 18 Learning Paths
  • Industry Leading Experts
  • Live Interactive Workshops
Get Unlimited Access Now

Table of Contents

Code Transformation and Linting with Abstract Syntax Trees

Section Duration: 3 minutes

Abstract Syntax Trees

Section Duration: 38 minutes
  • Examples of Abstract Syntax Trees
    Kent discusses the importance of Abstract Syntax Trees (AST) by examining examples where they are used: plugins for Babel and ESLint as well as within Codemods.
  • Introducing Abstract Syntax Trees
    Through visual and online demonstrations, Kent discusses what an Abstract Syntax Tree (AST) is. AST is a visual tree representation of the abstract syntax of programming code. AST's can help aid in learning how programming works by quickly seeing the progression of code through a program.
  • Exploring ASTs
    To demonstrate the power of AST, Kent will review three use cases in the course: building out Babel and ESLint plugins, and then showing how to use AST with Codemods. Using the AST Explorer tool, Kent starts with an ESLint example to show how to traverse AST so that programmers can track stylistic code, logical problems, or domain specific issues to keep bugs from entering the codebase.

ESLint Plugin and AST

Section Duration: 1 hour, 15 minutes

Babel Plugin and AST

Section Duration: 51 minutes

Codemods and AST

Section Duration: 38 minutes

Wrapping Up Code Transformation and Linting with Abstract Syntax Trees

Section Duration:

Learn Straight from the Experts Who Shape the Modern Web

  • In-depth Courses
  • Industry Leading Experts
  • Learning Paths
  • Live Interactive Workshops
Get Unlimited Access Now