Skip to content

Commit

Permalink
Update docs to add default formatter config
Browse files Browse the repository at this point in the history
  • Loading branch information
sovetski authored Aug 3, 2024
1 parent 9780541 commit 2771144
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,16 @@ or right mouse context menu on explorer `php-cs-fixer: fix`
}
```

TIPS: If you are using other formatters like Prettier, you can get some conflicts with auto save or other features. To fix it, you have to add this line:

```JSON5
// Set PHP CS Fixer as the default formatter for PHP files
// It will avoid conflict with other formatters like prettier etc.
"[php]": {
"editor.defaultFormatter": "junstyle.php-cs-fixer"
},
```

install php-cs-fixer by composer

```JSON
Expand Down

0 comments on commit 2771144

Please sign in to comment.