Commit Graph

1897 Commits (44bad41b3e81f96f872b2cd30f3266de3686c047)

Author SHA1 Message Date
Thomas Broadley 44bad41b3e Fix typo (#3467) 2017-12-13 01:44:49 -02:00
James Leftley 46ecf3ffbb Update ESLint docs code formatting for consistency (#3466) 2017-12-13 00:57:21 -02:00
Lucas Duailibe 4090bd6303 Update prettier's prettier to 1.9.2 2017-12-12 01:55:44 -02:00
Lucas Duailibe 7c83ac782e Regression test for #1473 2017-12-12 01:30:20 -02:00
Lucas Duailibe 694f9c8588
Print comment after arrow function params (#3444) 2017-12-12 01:26:41 -02:00
James Henry dc91108453 Update tsep and apply breaking changes (#3455) 2017-12-12 01:20:54 -02:00
Lucas Duailibe 76c5d91ce6 1.9.2 2017-12-12 01:15:12 -02:00
Roger Sheen 5065608f73 Docs: Add info on ignore file to "Ignoring Code" (#3458)
* docs(ignore): mention ignore file in Ignoring Code

While working on #3321, I needed to ignore an entire file, but the "Ignoring Code" section of the docs only describes how to ignore blocks of code, so I wasn't aware of the default ignore file.

(The `.prettierignore` file is mentioned in the CLI section, but easily overlooked there.)

This commit extends the introduction sentence of the "Ignoring Code" section and adds a new subsection to explain how to ignore files.

https://github.com/prettier/prettier/issues/3321#issuecomment-350072566

* docs(cli): fix nesting error in heading hierarchy

The `--ignore-path` option currently appears as a third-level subsection of `--find-config-path` and `--config`, but this looks like an error.

This commit promotes the `--ignore-path` heading to the same (H2) level as the other CLI options.
2017-12-11 22:23:06 -02:00
Lucas Duailibe d00d09bb87
Don't break single argument destructuring arguments (#3443) 2017-12-10 12:29:09 -02:00
Brian Ng 38c8286907 Fix closing parens on multi-line intersection/union type (#3436) 2017-12-10 22:32:17 +11:00
Lucas Duailibe 3fa2229a62 Fix printing union types inside a function param type (#3446)
* Fix printing union types inside a function param type

* fix alignment
2017-12-10 20:22:13 +11:00
Lucas Duailibe dbf22eb41a
Fix printing separator in objects with prettier-ignore (#3448) 2017-12-10 02:57:42 -02:00
Lucas Duailibe 69f05e42c9
Consider TSNonNullExpression part of member chain (#3442) 2017-12-10 02:41:53 -02:00
Lucas Duailibe c9079926c9
Improve visibility of lint-staged usage warning (#3445) 2017-12-10 00:09:07 -02:00
Lucas Duailibe 934e4d3027
Fix babylon misplacing comments (#3441)
* Fix comments in class method args

* Fix comments in obj property
2017-12-09 15:43:19 -02:00
Joseph Frazier 4f24892e53 Treat absent .editorconfig correctly (#3439)
This fixes https://github.com/prettier/prettier/issues/3432, I think.
2017-12-08 09:03:49 +11:00
Lucas Duailibe 69f6ee7829
Only prevent lone `get` and `set` if property has no value (#3434) 2017-12-07 11:03:55 -02:00
Lucas Duailibe 90e8b13e86
Ignore whitespace in docblock right after /** (#3430) 2017-12-07 03:28:29 -02:00
Lucas Duailibe 7cff189dd8
Print trailing comma when last arg is arrow (#3428) 2017-12-07 02:48:11 -02:00
Alf Eaton 67ec3b2f05 Update instructions for File Watcher in WebStorm (#3424)
Re-use the instructions for setting the File Watcher program path in WebStorm when prettier is installed locally.
2017-12-06 13:35:56 -02:00
Maxime Thirouin a9502f0ab7 Add "md" extension in "Pre-commit hook" documentation (#3421)
It's nice to have all extensions so we can easily copy paste :)
2017-12-06 20:34:58 +11:00
Ika 47f05d12f5
docs(changelog): fix typo (#3420) 2017-12-06 13:20:01 +08:00
Lipis 20373d6fee Prettify style in playground and code block languages (#3419) 2017-12-05 19:48:11 -07:00
Lucas Duailibe 2663fd8c6d Fix flow parser + fix CHANGELOG lint 2017-12-05 22:13:38 -02:00
Lucas Duailibe 54c31eeb78
Include CHANGELOG for 1.9.1 2017-12-05 22:04:47 -02:00
Lucas Duailibe 36c6e8368f
Bump prettier to 1.9.1 (#3416) 2017-12-05 21:56:49 -02:00
Lucas Duailibe a2c0a78cef 1.9.1 2017-12-05 21:33:19 -02:00
Lipis 23b8224240 Change cursor and remove outline in summaries on playground (#3415) 2017-12-05 21:21:02 -02:00
Lucas Duailibe 36a11b86bc Fix multiparser on playground (#3407)
* Fix multiparser in playground

* Remove unnecessary function call
2017-12-06 09:14:02 +11:00
Lucas Duailibe 7b299fb94e
Skip folders in CLI pattern (#3411) 2017-12-05 20:01:59 -02:00
Lucas Duailibe c34608f8ed
Bump editorconfig-to-prettier (#3412) 2017-12-05 19:01:48 -02:00
Lucas Duailibe 40af2e0514 Show a right border on sidebar 2017-12-05 18:29:49 -02:00
Lucas Duailibe 8bb6e169e2
Change playground options layout (#3374) 2017-12-05 17:54:07 -02:00
Lucas Duailibe c986f45ec7 fix lint 2017-12-05 17:48:10 -02:00
Lucas Duailibe 46f657bbaa add another test case 2017-12-05 16:30:21 -02:00
Lucas Duailibe 639c523885 Skip folders in CLI pattern 2017-12-05 16:07:27 -02:00
Lucas Azzola 829616dd6c Fix multiparser trailing comma regression (#3405)
* Fix multiparser trailing comma regression

* Refactor trailing comma application
2017-12-05 19:01:00 +01:00
Ika e09359d242
fix(doc-printer): no wrong function call (#3401) 2017-12-05 20:09:36 +08:00
Lucas Duailibe 66c9315d13
Don't default print comments for JSXFragments (#3398) 2017-12-05 08:41:45 -02:00
Ika f3e7ca2210 chore(playground): add new options (#3350) 2017-12-05 21:22:10 +11:00
Lucas Azzola c7c1d2e7a4 Upgrade Prettier to Prettier 1.9 (#3395)
* Upgrade to prettier@1.9.0

* Run eslint --fix

* Run prettylint --fix

* Fix playground with editorconfig script
2017-12-05 08:14:03 -02:00
Lucas Azzola 35fc6a6671 1.9.0 2017-12-05 10:23:51 +11:00
Joseph Frazier cecf0657a5 Re-add EditorConfig support (undo #3213) (#3255)
* Revert "Revert "Respect EditorConfig settings" (#3213)"

This reverts commit d2241fc0d5.

* Comment out EditorConfig docs

See https://github.com/prettier/prettier/pull/3213#issuecomment-343009769

* editorconfig: Support `indent_size = 0`

See https://github.com/prettier/prettier/pull/2760#discussion_r137447715
and c38b84c42a

* Revert "Comment out EditorConfig docs"

This reverts commit ddfa529c55cac4853a1e76e00c8b5e3ef158c01f.

* Mark EditorConfig functionality as v1.9.0+

See https://github.com/prettier/prettier/pull/3255#discussion_r150432508

* editorconfig: Upgrade editorconfig-to-prettier to 0.0.4

* editorconfig: Only enable for CLI, by default

https://github.com/prettier/prettier/pull/3255#issuecomment-348420546

* editorconfig: Add tests confirming that editorconfig is ignored by default in the API

https://github.com/prettier/prettier/pull/3255#issuecomment-348420546

* editorconfig: Add/fix CLI option parsing

* editorconfig: Move docs from configuration.md to options.md

* editorconfig: Add `oppositeDescription` to show docs for `--no-editorconfig`

Addresses https://github.com/prettier/prettier/pull/3255#discussion_r154542792

* editorconfig: Update test snapshots

* editorconfig: Remove unnecessary options parsing code

Addresses https://github.com/prettier/prettier/pull/3255#discussion_r154544560

* editorconfig: Move docs from options.md to api.md and cli.md

Addresses https://github.com/prettier/prettier/pull/3255#discussion_r154545979

* resolveConfig: return null if both .prettierrc and .editorconfig are missing

Addresses https://github.com/prettier/prettier/pull/3255#discussion_r154574613

* Don't add now-failing tests

The way these tests work, both `tests_integration/cli/config/.prettierrc`
and `.prettierrc` apply to `tests_integration/cli/config/editorconfig/file.shouldnotexist`,
so the test wouldn't work even on master. Here's a way to confirm that:

```js
const path = require('path')
const assert = require('assert')
const prettier = require('./')

const file = './tests_integration/cli/config/editorconfig/file.shouldnotexist'
console.log(prettier.resolveConfig.sync(file))
assert(prettier.resolveConfig.sync(file) === null)
```
2017-12-05 09:28:27 +11:00
Ika 1122701053 fix(doc-printer): respect indent/align order (#3383) 2017-12-05 08:59:27 +11:00
Kevin Gibbons 8e377a1e56 Add support for flow mixins when using babylon (#3391) 2017-12-05 08:58:14 +11:00
Marko Schulz a05811f8eb Fix link (#3392) 2017-12-05 08:55:32 +11:00
Lipis 475b2ab630 chore: Update packages to the latest patches (#3377) 2017-12-04 13:28:56 -07:00
Chris Burgin 38b490b092 Fixed website footer on mobile (#3335) (#3373) 2017-12-04 12:27:14 +11:00
Lucas Duailibe ceabc48e01
Format CSS prop for emotion (#3381) 2017-12-03 03:25:17 -03:00
Ika c1623d88e6 feat(markdown): preserve `break` style (#3325) 2017-12-03 15:02:13 +11:00