diff --git a/src/Formatters/PrettierFormatter.php b/src/Formatters/PrettierFormatter.php index 5d4d594..34ba901 100644 --- a/src/Formatters/PrettierFormatter.php +++ b/src/Formatters/PrettierFormatter.php @@ -9,7 +9,7 @@ class PrettierFormatter implements Formatter { public function format(string $file): void { - $process = new Process(['prettier', '--write', $file]); + $process = new Process(['npx', '--yes', 'prettier', '--write', $file]); $process->run(); if (! $process->isSuccessful()) {