## React rocks with quick-lint-js 2.0

2022-02-04

We are proud to announce version 2.0 of quick-lint-js!

React is the most used web framework in 2021. With quick-lint-js version 2.0, coding with React is easier than ever. Just install the quick-lint-js VS Code extension and catch your mistakes before you press `⌘-S`.

- install quick-lint-js
- 🌐 try in your browser
- code on GitHub

Notable quick-lint-js 2.0 features:

- JSX (React) support
- Over 340 times faster than ESLint for React code
- 18 new errors

See the full change log here.

How does quick-lint-js compare to ESLint? See for yourself:

ESLint

    let headingLinks = [];
    for (let el of $("a")) {
      if (el.parentNode.tag = "H1") {
        headingLinks.push(el);
      }
    }

Expected a conditional expression and instead saw an assignment;
Unexpected constant condition

quick-lint-js

    let headingLinks = [];
    for (let el of $("a")) {
      if (el.parentNode.tag = "H1") {
        headingLinks.push(el);
      }
    }

'=' changes variables; to compare, use '===' instead [E0188]

ESLint

    function TodoEntry({title, children}) {
      return (
        <h3>{title}</h3>
        <div className="body">{children}</div>
      );
    }

Adjacent JSX elements must be wrapped in an enclosing tag

quick-lint-js

    function TodoEntry({title, children}) {
      return (
        <h3>{title}</h3>
        <div className="body">{children}</div>
      );
    }

missing '<>' and '</>' to enclose multiple children;
children end here [E0189]

ESLint

    function Link({text, ...props}) {
      return <a {props}>{text}</a>;
    }

Parsing error: Unexpected token props

quick-lint-js

    function Link({text, ...props}) {
      return <a {props}>{text}</a>;
    }

missing '...' in JSX attribute spread [E0186]

What should we work on next? Suggest features for quick-lint-js.

quick-lint-js version 2.0 has over 230 patches since version 1.0. 37 people made quick-lint-js possible.

- install quick-lint-js
- 🌐 try in your browser
- code on GitHub

Written by strager, lead developer of quick-lint-js.