Skip to content

Instantly share code, notes, and snippets.

View gustavwennerblom's full-sized avatar

Gustav Wennerblom gustavwennerblom

  • Stockholm, Sweden
  • 10:49 (UTC +02:00)
View GitHub Profile
@gustavwennerblom
gustavwennerblom / gist:b17a6b8c12a6e10f88306ad3e42f26bd
Last active November 23, 2022 23:43
Adding prettier to a CRA project

Adding prettier to a CRA project

Previously, I've had some problem to reliaby configure code formatting with Prettier in VSCode, in the context of a create-react-app proejct. Today, it worked like a charm, and this is what I did.

Preconditions:

  • react-scripts: "3.1.1"
  • react: "^16.9.0"
  • react-dom: "^16.9.0"
  • Dirk Baeumer's ESLint VSCode extension installed and running