EditorConfig and Prettier can be used together to configure indentation style and other whitespace settings for any file type
, while avoiding redundant configuration.
Prettier is used to format already written code, while EditorConfig can be used in more languages and projects than Prettier.
The eslint-config-prettier package can be used to deactivate all ESLint rules that might conflict with Prettier.
This issue is about the need for support for.editorconfig, a configuration file that would allow users to configure line breaks and tab characters. It has been discussed in various forums, and the proposal has been proposed by several people, including a wrapper for prettier_d, which adds support for.editorconfig's indent_style, tab_width, and max_line_length properties. The proposal has been met with support from developers, and is being discussed in various ways.
Consider respecting EditorConfig file for whitespace and encoding options · Issue #42 · prettier/prettier · GitHub
EditorConfig allows you to define indentation style and other whitespace settings for any file type. This way your editor can automatically choose the correct settings. This is handy when developers use platforms with different line endings, e.g., Mac and Windows.
If you want to run Prettier programmatically, check this page out.
API · Prettier
This article provides guidelines on how to configure ESLint, Prettier, and EditorConfig without any conflicts while also avoiding redundant configuration. It explains the underlying issues of code formatting and how to use the right tool for the right issue, as well as how to integrate Prettier with ESLint and ESLint. Finally, it provides a step-by-step guide on how to use the eslint-config-prettier package to deactivate all ESLint rules that might conflict with Prettier.
Set up ESlint, Prettier & EditorConfig without conflicts | Theodo
EditorConfig's role is to configure your editor so that the code you write is already formatted while Prettier will format your already written code . This allows EditorConfig to be used in many more languages and projects than Prettier.
Why You Should Use ESLint, Prettier & EditorConfig | Theodo
Use the `prettier` command to run Prettier from the command line.
CLI · Prettier