Add pre-commit hook for formatting

This commit is contained in:
Eli Ribble 2024-08-27 09:36:36 -07:00
parent 91600be038
commit 9033b9862a
2 changed files with 9 additions and 0 deletions

8
.pre-commit-config.yaml Normal file
View File

@ -0,0 +1,8 @@
repos:
- repo: local
hooks:
- id: prettier
name: prettier
language: system
entry: npx prettier --write
files: '\.tsx$'

View File

@ -5,6 +5,7 @@ stdenv.mkDerivation {
buildInputs = with pkgs; [
create-react-app
nodejs
pre-commit
yarn
];
shellHook = ''