Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3371377
D3918.id12253.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
891 B
Referenced Files
None
Subscribers
None
D3918.id12253.diff
View Options
diff --git a/.eslintrc.json b/.eslintrc.json
--- a/.eslintrc.json
+++ b/.eslintrc.json
@@ -15,6 +15,13 @@
"parser": "babel-eslint",
"plugins": ["react", "react-hooks", "flowtype", "monorepo", "import"],
"rules": {
+ // Prettier is configured to keep lines to 80 chars, but there are two issues:
+ // - It doesn't handle comments (leaves them as-is)
+ // - It makes all import statements take one line (reformats them)
+ // We want ESLint to warn us in the first case, but not in the second case
+ // since Prettier forces us in the second case. By setting code to 420, we
+ // make sure ESLint defers to Prettier for import statements.
+ "max-len": ["error", { "code": 420, "comments": 80, "ignoreUrls": true }],
"flowtype/require-valid-file-annotation": ["error", "always"],
"flowtype/require-exact-type": ["error", "never"],
"curly": "error",
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Nov 27, 4:44 AM (21 h, 59 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2587374
Default Alt Text
D3918.id12253.diff (891 B)
Attached To
Mode
D3918: [root] [chore] [ENG-1083] update eslint config to enforce comment width to 80 characters
Attached
Detach File
Event Timeline
Log In to Comment