Update js languages (#9073)
This commit is contained in:
1 parent
fadd93571d
commit
c8e7e0b003
2 files changed
+16
-10
No files matched your search
@@ -10,9 +10,9 @@ const languages = [
|
||||
require("linguist-languages/data/JavaScript.json"),
|
||||
(data) => ({
|
||||
since: "0.0.0",
|
||||
parsers: ["babel", "flow"],
|
||||
parsers: ["babel", "babel-flow", "babel-ts", "flow", "typescript"],
|
||||
vscodeLanguageIds: ["javascript", "mongo"],
|
||||
interpreters: data.interpreters.concat(["nodejs"]),
|
||||
interpreters: [...data.interpreters, "nodejs"],
|
||||
extensions: [
|
||||
...data.extensions,
|
||||
// WeiXin Script (Weixin Mini Programs)
|
||||
@@ -24,7 +24,7 @@ const languages = [
|
||||
createLanguage(require("linguist-languages/data/JavaScript.json"), () => ({
|
||||
name: "Flow",
|
||||
since: "0.0.0",
|
||||
parsers: ["babel", "flow"],
|
||||
parsers: ["flow", "babel-flow"],
|
||||
vscodeLanguageIds: ["javascript"],
|
||||
aliases: [],
|
||||
filenames: [],
|
||||
@@ -32,7 +32,7 @@ const languages = [
|
||||
})),
|
||||
createLanguage(require("linguist-languages/data/JSX.json"), () => ({
|
||||
since: "0.0.0",
|
||||
parsers: ["babel", "flow"],
|
||||
parsers: ["babel", "babel-flow", "babel-ts", "flow", "typescript"],
|
||||
vscodeLanguageIds: ["javascriptreact"],
|
||||
})),
|
||||
createLanguage(require("linguist-languages/data/TypeScript.json"), () => ({
|
||||
@@ -57,7 +57,7 @@ const languages = [
|
||||
since: "1.5.0",
|
||||
parsers: ["json"],
|
||||
vscodeLanguageIds: ["json"],
|
||||
filenames: data.filenames.concat([".prettierrc"]),
|
||||
filenames: [...data.filenames, ".prettierrc"],
|
||||
})),
|
||||
createLanguage(
|
||||
require("linguist-languages/data/JSON with Comments.json"),
|
||||
@@ -65,7 +65,7 @@ const languages = [
|
||||
since: "1.5.0",
|
||||
parsers: ["json"],
|
||||
vscodeLanguageIds: ["jsonc"],
|
||||
filenames: data.filenames.concat([".eslintrc"]),
|
||||
filenames: [...data.filenames, ".eslintrc"],
|
||||
})
|
||||
),
|
||||
createLanguage(require("linguist-languages/data/JSON5.json"), () => ({
|
||||
|
||||
@@ -10,8 +10,8 @@ Object {
|
||||
"css",
|
||||
],
|
||||
"Flow": Array [
|
||||
"babel",
|
||||
"flow",
|
||||
"babel-flow",
|
||||
],
|
||||
"GraphQL": Array [
|
||||
"graphql",
|
||||
@@ -33,11 +33,17 @@ Object {
|
||||
],
|
||||
"JSX": Array [
|
||||
"babel",
|
||||
"babel-flow",
|
||||
"babel-ts",
|
||||
"flow",
|
||||
"typescript",
|
||||
],
|
||||
"JavaScript": Array [
|
||||
"babel",
|
||||
"babel-flow",
|
||||
"babel-ts",
|
||||
"flow",
|
||||
"typescript",
|
||||
],
|
||||
"Less": Array [
|
||||
"less",
|
||||
@@ -307,7 +313,7 @@ exports[`CLI --support-info (stdout) 1`] = `
|
||||
],
|
||||
\\"linguistLanguageId\\": 183,
|
||||
\\"name\\": \\"JavaScript\\",
|
||||
\\"parsers\\": [\\"babel\\", \\"flow\\"],
|
||||
\\"parsers\\": [\\"babel\\", \\"babel-flow\\", \\"babel-ts\\", \\"flow\\", \\"typescript\\"],
|
||||
\\"since\\": \\"0.0.0\\",
|
||||
\\"tmScope\\": \\"source.js\\",
|
||||
\\"type\\": \\"programming\\",
|
||||
@@ -334,7 +340,7 @@ exports[`CLI --support-info (stdout) 1`] = `
|
||||
],
|
||||
\\"linguistLanguageId\\": 183,
|
||||
\\"name\\": \\"Flow\\",
|
||||
\\"parsers\\": [\\"babel\\", \\"flow\\"],
|
||||
\\"parsers\\": [\\"flow\\", \\"babel-flow\\"],
|
||||
\\"since\\": \\"0.0.0\\",
|
||||
\\"tmScope\\": \\"source.js\\",
|
||||
\\"type\\": \\"programming\\",
|
||||
@@ -348,7 +354,7 @@ exports[`CLI --support-info (stdout) 1`] = `
|
||||
\\"group\\": \\"JavaScript\\",
|
||||
\\"linguistLanguageId\\": 178,
|
||||
\\"name\\": \\"JSX\\",
|
||||
\\"parsers\\": [\\"babel\\", \\"flow\\"],
|
||||
\\"parsers\\": [\\"babel\\", \\"babel-flow\\", \\"babel-ts\\", \\"flow\\", \\"typescript\\"],
|
||||
\\"since\\": \\"0.0.0\\",
|
||||
\\"tmScope\\": \\"source.js.jsx\\",
|
||||
\\"type\\": \\"programming\\",
|
||||
|
||||
Reference in new issue
Block a user