Skip to content
This repository was archived by the owner on Sep 27, 2023. It is now read-only.

Commit 7ee04dc

Browse files
committed
[Example] Switch to tslint and use tslint-plugin-relay
1 parent 6cc98bc commit 7ee04dc

File tree

6 files changed

+86
-359
lines changed

6 files changed

+86
-359
lines changed

example/.eslintignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

example/.eslintrc

Lines changed: 0 additions & 4 deletions
This file was deleted.

example/package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"build":
66
"relay-compiler --src ./ts/ --schema ./data/schema.graphql --language typescript --artifactDirectory ./ts/__relay_artifacts__",
77
"update-schema": "babel-node ./scripts/updateSchema.js",
8-
"lint": "eslint ./js",
8+
"lint": "tslint --project tsconfig.json",
99
"type-check": "tsc --noEmit --pretty"
1010
},
1111
"resolutions": {
@@ -48,7 +48,6 @@
4848
"babel-cli": "^6.26.0",
4949
"babel-eslint": "6.1.2",
5050
"csstype": "^2.5.6",
51-
"eslint": "3.19.0",
5251
"eslint-config-fbjs": "1.1.1",
5352
"eslint-plugin-babel": "3.3.0",
5453
"eslint-plugin-flowtype": "2.15.0",
@@ -58,6 +57,8 @@
5857
"relay-compiler-language-typescript":
5958
"file:../relay-compiler-language-typescript-1.1.1-alpha.1.tgz",
6059
"ts-loader": "^3.2.0",
60+
"tslint": "^5.12.0",
61+
"tslint-plugin-relay": "^0.0.3",
6162
"typescript": "2.9.1"
6263
}
6364
}

example/tsconfig.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,5 @@
77
"strict": true,
88
"target": "es2015"
99
},
10-
"exclude": [
11-
"node_modules"
12-
]
10+
"exclude": ["node_modules"]
1311
}

example/tslint.json

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"defaultSeverity": "error",
3+
"extends": ["tslint:recommended", "tslint-plugin-relay"],
4+
"jsRules": {},
5+
"rules": {
6+
"arrow-parens": false,
7+
"interface-name": false,
8+
"object-literal-sort-keys": false,
9+
"variable-name": false,
10+
"trailing-comma": false,
11+
"quotemark": false,
12+
"ordered-imports": false,
13+
"no-console": false,
14+
"semicolon": false,
15+
"member-access": false,
16+
"curly": false,
17+
"object-literal-shorthand": false
18+
},
19+
"rulesDirectory": []
20+
}

0 commit comments

Comments
 (0)