Commit Graph

16 Commits (master)

Author SHA1 Message Date
David Lechner 1435b2756c docs/configuration: specify order of precedence (#6638)
This updates the docs to show the search order of the config files.

Order comes from: 3805034bdf/src/config/resolve-config.js (L35-L44)
2019-10-12 19:26:07 +02:00
Simon Lydell 2827543154
Improve overrides documentation (#6416)
Refs. #6415.
2019-08-27 07:09:12 +02:00
Lucas Azzola f32b289032
Support shared Prettier configuration (#5963)
* Support external configuration

* Document changes

* Update existing snapshots

* Update existing snapshots (2)

* Fix typo in docs

* Add example config repo
2019-03-13 09:34:51 +11:00
Wei-Wei Wu 91c20f7fbe Rename "babylon" with "babel" (#5647) 2018-12-27 21:05:19 +08:00
Simon Lydell dc590e5e4b
Improve documentation for the parser option (#5129)
- Warn about setting parser at the top level. Refs. #4638.
- Remove top level parser from examples. Instead show the most common
options (I also removed printWidth, since we don't recommend changing
it). Refs. #4638.
- Show how to configure the flow parser for .js files. Refs. #4638.
- Update valid options for the parser option, including links and "since
version".
- Clarify babylon vs flow.
2018-09-29 09:40:19 +02:00
David dda7c265d0 Update configuration to be clearer about js config (#4993)
So in the list, it says to use `prettier.config.js` as your file name for configuring prettier in js. But in the example it has `//.prettierrc.js`. This confused me so I tried both file names. Both these file names work to configure prettier so I updated the docs to reflect that.
2018-08-20 12:33:02 +08:00
Jorge Gonzalez 7d78ce68ef feat(config): support TOML configuration files (#4877)
* Add initial support for TOML in configuration files

* Missed brace

* Fix snapshots

* refactor: move loadToml to utils

* Use @iarna/toml

* Add tests for loadToml

* Fix test for CI

* Remove jest-extended

* Create snapshot for load-toml

* Add feat to docs

* lint docs

* Use @iarna/toml/parse-string

* Change path string
2018-08-03 06:27:19 -04:00
Ika 514fcb835a chore: bump Prettier dependency to 1.14.0 2018-07-29 15:44:21 +08:00
Lucas Duailibe 412b064df8 Format docs with Prettier 1.13 2018-05-27 15:38:31 -03:00
Josh Unger 358984ef0c add an example .prettierrc.js config (#3570)
* add an example .prettierrc.js config

* Update configuration.md
2017-12-26 18:26:09 +11:00
Josh Unger 62bfcac4c5 remove comment in prettier json example since comments are invalid in json (#3567)
remove comment in prettier json file example since comments are invalid in json
2017-12-26 01:15:18 +11:00
Ika 76efb33e75 chore: setup markdown formatting (#3224)
* chore(deps): upgrade prettier to v1.8.2

* chore: setup lint-docs script

* docs: add `<!-- prettier-ignore -->`s

* docs: format docs

* Revert "docs: format docs"

This reverts commit 6dba903987dddc498cb589ca311905f25b6aee53.

* chore(prettierrc): set `--no-prose-wrap`

* docs: format docs

* Revert "docs: format docs"

This reverts commit 139bd744b6921916be8fac4fa3bab83bae5d12df.

* docs: tweak

* docs: format docs

* chore: rename .prettierrc

* chore: rename back to .prettierrc

* chore: split out third-party

* refactor: fix linting

* chore: do not split out third-party on website
2017-11-22 22:27:40 +11:00
Nathaniel Furniss cbed0f487f fix config doc typo (#3298) 2017-11-20 18:26:33 -02:00
Lucas Azzola d2241fc0d5
Revert "Respect EditorConfig settings" (#3213)
* Revert "Respect EditorConfig settings (#2760)"

This reverts commit 8f58ca0f48.
2017-11-09 11:38:58 +11:00
Joseph Frazier 8f58ca0f48
Respect EditorConfig settings (#2760)
This fixes https://github.com/prettier/prettier/issues/42.
It adds support for .editorconfig's `indent_style`, `indent_size`, `tab_width`,
and `max_line_length` properties.

It doesn't support the `end_of_line` property as described in
https://github.com/prettier/prettier/issues/42#issuecomment-327073326,
but that could be added later. The same goes for `quote_type`
(https://github.com/prettier/prettier-atom/issues/293#issue-267288335).

* Make test .prettierrc not set config for all file extensions

This makes it easier to keep tests isolated.
2017-11-08 14:30:28 -05:00
Lucas Azzola 71a5533c4e
Move all docs to website (#3139)
* Sync README -> docs/options.md

* Sync README -> docs/*.md

* Misc fixups

* Remove markdown-toc

* Remove insert-pragma from ToC

* Never again!

* Move all docs to ./docs

* Remove yarn toc

* Fix inter-doc links

* Fix links in footer

* Clean up README.md

* Add basic description to README.md

* Use flat badges

* Move editor guides to website

* Improve prettier-ignore docs

* Fixup bad find/replace

* Add JSON to README

* Fix custom parser API link

* Fixup GitHub centering, add downloads badge

* Add 1.8 docs

* docs(website): mention markdown on homepage (#1)

* Add intro

* Add watching-files.md

* Fix markdown syntax highlighting

* Switch back to .md links
2017-11-07 14:39:07 +11:00