Current Behavior
Using the --files arg determines allowed extensions with prettier.getSupportInfo() without loading Prettier plugins. In my case, I need the prettier-plugin-svelte plugin to format .svelte files. Instead I am forced to use the prettier --write {files}. Also a warning/error would be nice for file extensions not supported or forward the error from Prettier.
Same closed issue: #21250
Expected Behavior
nx format with the --files arg should use Prettier's plugins for non default extension support.
GitHub Repo
No response
Steps to Reproduce
- Create a "something.svelte" file with formatting issues.
- Install
prettier-plugin-svelte prettier plugin.
- Run
nx format --files={something.svelte}.
- The svelte file will not be processed, no change in diff file.
Nx Report
Node : 22.15.0
OS : darwin-arm64
Native Target : aarch64-macos
pnpm : 10.32.1
nx (global) : 21.1.2
nx : 22.2.3
@nx/js : 22.2.3
@nx/eslint : 22.2.3
@nx/workspace : 22.2.3
@nx/devkit : 22.2.3
@nx/esbuild : 22.2.3
@nx/eslint-plugin : 22.2.3
@nx/node : 22.2.3
@nx/playwright : 22.2.3
@nx/plugin : 22.2.3
@nx/react : 22.2.3
@nx/rollup : 22.2.3
@nx/vite : 22.2.3
@nx/vitest : 22.2.3
@nx/web : 22.2.3
@nx/webpack : 22.2.3
typescript : 5.9.3
---------------------------------------
Registered Plugins:
@nx/eslint/plugin
@nx/playwright/plugin
---------------------------------------
Community plugins:
@nxext/svelte : 18.0.0
@nxext/sveltekit : 18.0.0
nx-stylelint : 17.1.1
---------------------------------------
Local workspace plugins:
@ctv/compile-time-config
---------------------------------------
Cache Usage: 1.38 MB / 46.04 GB
---------------------------------------
Failure Logs
Package Manager Version
No response
Operating System
Additional Information
Current Behavior
Using the
--filesarg determines allowed extensions withprettier.getSupportInfo()without loading Prettier plugins. In my case, I need theprettier-plugin-svelteplugin to format.sveltefiles. Instead I am forced to use theprettier --write {files}. Also a warning/error would be nice for file extensions not supported or forward the error from Prettier.Same closed issue: #21250
Expected Behavior
nx formatwith the--filesarg should use Prettier's plugins for non default extension support.GitHub Repo
No response
Steps to Reproduce
prettier-plugin-svelteprettier plugin.nx format --files={something.svelte}.Nx Report
Failure Logs
Package Manager Version
No response
Operating System
Additional Information