X Tutup
The Wayback Machine - https://web.archive.org/web/20201231182048/https://github.com/facebook/docusaurus/pull/2542
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(v2): update Prettier config #2542

Merged
merged 3 commits into from Apr 5, 2020
Merged

chore(v2): update Prettier config #2542

merged 3 commits into from Apr 5, 2020

Conversation

@lex111
Copy link
Collaborator

@lex111 lex111 commented Apr 5, 2020

Motivation

Update config Prettier so that it is consistent with the latest version of ESLint config Airbnb , where you now always need to write parentheses 😢

https://github.com/airbnb/javascript#arrows--one-arg-parens

Have you read the Contributing Guidelines on pull requests?

Yes

Test Plan

N/A.

Related PRs

(If this PR adds or changes functionality, please take some time to update the docs at https://github.com/facebook/docusaurus, and link to your PR here.)

@lex111 lex111 changed the title chore(v2): update prettier config chore(v2): update Prettier config Apr 5, 2020
Copy link
Member

@yangshun yangshun left a comment

Oh man. Thanks

@yangshun
Copy link
Member

@yangshun yangshun commented Apr 5, 2020

According to https://prettier.io/blog/2020/03/21/2.0.0.html, that's the default option right? Why do we still have to manually specify?

@docusaurus-bot
Copy link
Collaborator

@docusaurus-bot docusaurus-bot commented Apr 5, 2020

Deploy preview for docusaurus-2 ready!

Built with commit 862375f

https://deploy-preview-2542--docusaurus-2.netlify.com

@docusaurus-bot
Copy link
Collaborator

@docusaurus-bot docusaurus-bot commented Apr 5, 2020

Deploy preview for docusaurus-2 ready!

Built with commit fb97c3c

https://deploy-preview-2542--docusaurus-2.netlify.com

@yangshun
Copy link
Member

@yangshun yangshun commented Apr 5, 2020

When I upgraded Prettier just now in #2538 I think all the arrow parens were updated. So I think it's the default option now without us having to do anything.

@lex111
Copy link
Collaborator Author

@lex111 lex111 commented Apr 5, 2020

Yes, but my code editor does not know about :)
And so it removes all the parentheses as earlier.

@yangshun
Copy link
Member

@yangshun yangshun commented Apr 5, 2020

Ok let's merge this since it's relatively harmless. But I think if your IDE is using your project's Prettier or has an upgraded Prettier, this wouldn't be an issue.

--
@yangshun yangshun merged commit 8f0206b into master Apr 5, 2020
0 of 4 checks passed
0 of 4 checks passed
build (10.x) build (10.x)
Details
ci/circleci: lint-prettier CircleCI is running your tests
Details
ci/circleci: tests CircleCI is running your tests
Details
deploy/netlify Deploy preview processing.
Details
@yangshun yangshun deleted the lex111/pre branch Apr 5, 2020
mohrash92 added a commit to mohrash92/docusaurus that referenced this pull request Apr 11, 2020
* chore(v2): update prettier config

* Update .prettierrc

* --

Co-authored-by: Yangshun Tay <tay.yang.shun@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.
X Tutup