mirror of
https://github.com/zed-industries/zed.git
synced 2024-11-08 07:35:01 +03:00
c290d924f1
This fixes #4529 by allowing unsaved buffers to be formatted with prettier. Steps to do that: 1. Create a new buffer 2. Set language for the buffer (e.g.: `language selector: toggle` and JSON) 3. In settings, set prettier parser for language (can't be inferred, since we don't have filename) and allow formatting with prettier: ```json { "languages": { "JSON": { "prettier": { "allowed": true, "parser": "json" } } } } ``` 4. Use `editor: format` Release Notes: - Added ability to format unsaved buffers with Prettier. Requirement is to set a Prettier parser in the user settings. Example for JSON: `{ "languages": { "JSON": { "prettier": { "allowed": true, "parser": "json" } } } }` ([#4529](https://github.com/zed-industries/zed/issues/4529)). Demo: https://github.com/zed-industries/zed/assets/1185253/d24e490b-2e2c-4a5d-95a8-fc8675523780 |
||
---|---|---|
.. | ||
src | ||
Cargo.toml | ||
LICENSE-GPL |