Skip to content

Commit 2acb918

Browse files
committed
feat: support flow syntax
1 parent 394c220 commit 2acb918

File tree

1 file changed

+53
-0
lines changed

1 file changed

+53
-0
lines changed

src/typescript.js

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,4 +6,57 @@ export function setupTypeScript() {
66
atom.config.set("atom-typescript.checkAllFilesOnSave", false)
77
// activate atom-typescript
88
atom.commands.dispatch(atom.workspace.getElement(), "typescript:activate")
9+
// support flow in JavaScript files
10+
atom.config.set("atom-typescript.ignoredDiagnosticCodes", ["8002", "8003", "8004", "8006", "8008", "8010"])
911
}
12+
13+
/*
14+
"'import ... =' can only be used in TypeScript files.": {
15+
"category": "Error",
16+
"code": 8002
17+
},
18+
"'export =' can only be used in TypeScript files.": {
19+
"category": "Error",
20+
"code": 8003
21+
},
22+
"Type parameter declarations can only be used in TypeScript files.": {
23+
"category": "Error",
24+
"code": 8004
25+
},
26+
"'implements' clauses can only be used in TypeScript files.": {
27+
"category": "Error",
28+
"code": 8005
29+
},
30+
"'{0}' declarations can only be used in TypeScript files.": {
31+
"category": "Error",
32+
"code": 8006
33+
},
34+
"Type aliases can only be used in TypeScript files.": {
35+
"category": "Error",
36+
"code": 8008
37+
},
38+
"The '{0}' modifier can only be used in TypeScript files.": {
39+
"category": "Error",
40+
"code": 8009
41+
},
42+
"Type annotations can only be used in TypeScript files.": {
43+
"category": "Error",
44+
"code": 8010
45+
},
46+
"Type arguments can only be used in TypeScript files.": {
47+
"category": "Error",
48+
"code": 8011
49+
},
50+
"Parameter modifiers can only be used in TypeScript files.": {
51+
"category": "Error",
52+
"code": 8012
53+
},
54+
"Non-null assertions can only be used in TypeScript files.": {
55+
"category": "Error",
56+
"code": 8013
57+
},
58+
"Type assertion expressions can only be used in TypeScript files.": {
59+
"category": "Error",
60+
"code": 8016
61+
},
62+
*/

0 commit comments

Comments
 (0)