Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
掘金者说
vscode
提交
554004be
V
vscode
项目概览
掘金者说
/
vscode
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
V
vscode
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
554004be
编写于
2月 17, 2016
作者:
D
Dirk Baeumer
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Fixes #3087: Remove JavaScript and TypeScript from VSCode
上级
1dc404e2
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
166 addition
and
178 deletion
+166
-178
.vscode/settings.json
.vscode/settings.json
+1
-1
src/vs/editor/editor.main.js
src/vs/editor/editor.main.js
+4
-1
src/vs/languages/javascript/common/javascript.contribution.ts
...vs/languages/javascript/common/javascript.contribution.ts
+161
-174
src/vs/languages/languages.main.js
src/vs/languages/languages.main.js
+0
-2
未找到文件。
.vscode/settings.json
浏览文件 @
554004be
...
...
@@ -12,6 +12,6 @@
"out*/**"
:
true
,
"extensions/**/out/**"
:
true
},
"tslint.enable"
:
tru
e
,
"tslint.enable"
:
fals
e
,
"tslint.rulesDirectory"
:
"node_modules/tslint-microsoft-contrib"
}
\ No newline at end of file
src/vs/editor/editor.main.js
浏览文件 @
554004be
...
...
@@ -9,7 +9,10 @@ define([
'
vs/editor/contrib/quickOpen/browser/quickOutline.contribution
'
,
'
vs/editor/contrib/quickOpen/browser/gotoLine.contribution
'
,
'
vs/editor/contrib/quickOpen/browser/quickCommand.contribution
'
,
'
vs/languages/languages.main
'
'
vs/languages/languages.main
'
,
"
vs/languages/javascript/common/javascript.contribution
"
,
"
vs/languages/typescript/common/typescript.contribution
"
,
"
vs/languages/json/common/json.contribution
"
],
function
()
{
});
\ No newline at end of file
src/vs/languages/javascript/common/javascript.contribution.ts
浏览文件 @
554004be
...
...
@@ -12,185 +12,172 @@ import {LanguageExtensions} from 'vs/editor/common/modes/languageExtensionPoint'
import
Options
=
require
(
'
vs/languages/typescript/common/options
'
);
let
defaults
=
Options
.
javaScriptOptions
;
let
enable
=
false
;
if
(
enable
)
{
LanguageExtensions
.
registerCompatMode
({
id
:
'
javascript
'
,
extensions
:
[
'
.js
'
,
'
.es6
'
],
firstLine
:
'
^#!.*
\\
bnode
'
,
filenames
:
[
'
jakefile
'
],
aliases
:
[
'
JavaScript
'
,
'
javascript
'
,
'
js
'
],
mimetypes
:
[
'
text/javascript
'
],
moduleId
:
'
vs/languages/javascript/common/javascript
'
,
ctorName
:
'
JSMode
'
});
LanguageExtensions
.
registerCompatMode
({
id
:
'
javascript
'
,
extensions
:
[
'
.js
'
,
'
.es6
'
],
firstLine
:
'
^#!.*
\\
bnode
'
,
filenames
:
[
'
jakefile
'
],
aliases
:
[
'
JavaScript
'
,
'
javascript
'
,
'
js
'
],
mimetypes
:
[
'
text/javascript
'
],
moduleId
:
'
vs/languages/javascript/common/javascript
'
,
ctorName
:
'
JSMode
'
});
// ----- Registration and Configuration --------------------------------------------------------
// ----- Registration and Configuration --------------------------------------------------------
var
configurationRegistry
=
<
ConfigurationRegistry
.
IConfigurationRegistry
>
platform
.
Registry
.
as
(
ConfigurationRegistry
.
Extensions
.
Configuration
);
var
configurationRegistry
=
<
ConfigurationRegistry
.
IConfigurationRegistry
>
platform
.
Registry
.
as
(
ConfigurationRegistry
.
Extensions
.
Configuration
);
configurationRegistry
.
registerConfiguration
({
'
id
'
:
'
javascript
'
,
'
order
'
:
20
,
'
type
'
:
'
object
'
,
'
title
'
:
nls
.
localize
(
'
jsConfigurationTitle
'
,
"
JavaScript configuration
"
),
'
allOf
'
:
[
{
'
type
'
:
'
object
'
,
'
title
'
:
nls
.
localize
(
'
suggestSettings
'
,
"
Controls how JavaScript IntelliSense works.
"
),
'
properties
'
:
{
'
javascript.suggest.alwaysAllWords
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
suggest
.
alwaysAllWords
,
'
description
'
:
nls
.
localize
(
'
allwaysAllWords
'
,
"
Always include all words from the current document.
"
),
},
'
javascript.suggest.useCodeSnippetsOnMethodSuggest
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
suggest
.
useCodeSnippetsOnMethodSuggest
,
'
description
'
:
nls
.
localize
(
'
useCodeSnippetsOnMethodSuggest
'
,
"
Complete functions with their parameter signature.
"
),
}
configurationRegistry
.
registerConfiguration
({
'
id
'
:
'
javascript
'
,
'
order
'
:
20
,
'
type
'
:
'
object
'
,
'
title
'
:
nls
.
localize
(
'
jsConfigurationTitle
'
,
"
JavaScript configuration
"
),
'
allOf
'
:
[
{
'
type
'
:
'
object
'
,
'
title
'
:
nls
.
localize
(
'
suggestSettings
'
,
"
Controls how JavaScript IntelliSense works.
"
),
'
properties
'
:
{
'
javascript.suggest.alwaysAllWords
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
suggest
.
alwaysAllWords
,
'
description
'
:
nls
.
localize
(
'
allwaysAllWords
'
,
"
Always include all words from the current document.
"
),
},
'
javascript.suggest.useCodeSnippetsOnMethodSuggest
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
suggest
.
useCodeSnippetsOnMethodSuggest
,
'
description
'
:
nls
.
localize
(
'
useCodeSnippetsOnMethodSuggest
'
,
"
Complete functions with their parameter signature.
"
),
}
}
,
{
'
title
'
:
nls
.
localize
(
'
compilationSettings
'
,
"
Controls how JavaScript validation works.
"
),
'
type
'
:
'
object
'
,
'
properties
'
:
{
'
javascript.validate.enable
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
true
,
'
description
'
:
nls
.
localize
(
'
vsclint
'
,
"
Controls VSCode's JavaScript validation. If set to false both syntax and semantic validation is disabled
"
)
,
}
,
'
javascript.validate.semanticValidation
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
validate
.
semanticValidation
,
'
description
'
:
nls
.
localize
(
'
semanticValidation
'
,
"
Run linter checks for JavaScript files - overrides validate.lint.* settings.
"
)
,
}
,
'
javascript.validate.syntaxValidation
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
validate
.
syntaxValidation
,
'
description
'
:
nls
.
localize
(
'
syntaxValidation
'
,
"
Check JavaScript files for syntax errors.
"
)
,
}
}
},
{
'
title
'
:
nls
.
localize
(
'
compilationSettings
'
,
"
Controls how JavaScript validation works.
"
)
,
'
type
'
:
'
object
'
,
'
properties
'
:
{
'
javascript.validate.enable
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
true
,
'
description
'
:
nls
.
localize
(
'
vsclint
'
,
"
Controls VSCode's JavaScript validation. If set to false both syntax and semantic validation is disabled
"
)
,
},
'
javascript.validate.semanticValidation
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
validate
.
semanticValidation
,
'
description
'
:
nls
.
localize
(
'
semanticValidation
'
,
"
Run linter checks for JavaScript files - overrides validate.lint.* settings.
"
)
,
},
'
javascript.validate.syntaxValidation
'
:
{
'
type
'
:
'
boolean
'
,
'
default
'
:
defaults
.
validate
.
syntaxValidation
,
'
description
'
:
nls
.
localize
(
'
syntaxValidation
'
,
"
Check JavaScript files for syntax errors.
"
),
}
},
{
'
type
'
:
'
object
'
,
'
title
'
:
nls
.
localize
(
'
lint
'
,
"
Controls various aspects of validation.
"
),
'
properties
'
:
{
'
javascript.validate.lint.curlyBracketsMustNotBeOmitted
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
curlyBracketsMustNotBeOmitted
,
'
description
'
:
nls
.
localize
(
'
lint.curlyBracketsMustNotBeOmitted
'
,
"
Don't spare curly brackets.
"
),
},
'
javascript.validate.lint.emptyBlocksWithoutComment
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
emptyBlocksWithoutComment
,
'
description
'
:
nls
.
localize
(
'
lint.emptyBlocksWithoutComment
'
,
"
Empty block should have a comment.
"
),
},
'
javascript.validate.lint.comparisonOperatorsNotStrict
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
comparisonOperatorsNotStrict
,
'
description
'
:
nls
.
localize
(
'
lint.comparisonOperatorsNotStrict
'
,
"
Use '!==' and '===' instead of '!=' and '=='.
"
),
},
'
javascript.validate.lint.missingSemicolon
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
missingSemicolon
,
'
description
'
:
nls
.
localize
(
'
lint.missingSemicolon
'
,
"
Missing semicolon.
"
),
},
'
javascript.validate.lint.unknownTypeOfResults
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unknownTypeOfResults
,
'
description
'
:
nls
.
localize
(
'
lint.unknownTypeOfResults
'
,
"
Unexpected output of the 'typeof' operator.
"
),
},
'
javascript.validate.lint.semicolonsInsteadOfBlocks
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
semicolonsInsteadOfBlocks
,
'
description
'
:
nls
.
localize
(
'
lint.semicolonsInsteadOfBlocks
'
,
"
Semicolon instead of block.
"
),
},
'
javascript.validate.lint.functionsInsideLoops
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
functionsInsideLoops
,
'
description
'
:
nls
.
localize
(
'
lint.functionsInsideLoops
'
,
"
Function inside loop.
"
),
},
'
javascript.validate.lint.newOnLowercaseFunctions
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
newOnLowercaseFunctions
,
'
description
'
:
nls
.
localize
(
'
lint.newOnLowercaseFunctions
'
,
"
Function with lowercase name used as constructor.
"
),
},
'
javascript.validate.lint.tripleSlashReferenceAlike
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
tripleSlashReferenceAlike
,
'
description
'
:
nls
.
localize
(
'
lint.tripleSlashReferenceAlike
'
,
"
Looks for mistyped triple-slash references.
"
),
},
'
javascript.validate.lint.unusedVariables
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unusedVariables
,
'
description
'
:
nls
.
localize
(
'
lint.unusedVariables
'
,
"
Unused local variable.
"
),
},
'
javascript.validate.lint.unusedFunctions
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unusedFunctions
,
'
description
'
:
nls
.
localize
(
'
lint.unusedFunctions
'
,
"
Unused local function.
"
),
},
}
},
{
'
type
'
:
'
object
'
,
'
title
'
:
nls
.
localize
(
'
lint
'
,
"
Controls various aspects of validation.
"
),
'
properties
'
:
{
'
javascript.validate.lint.curlyBracketsMustNotBeOmitted
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
curlyBracketsMustNotBeOmitted
,
'
description
'
:
nls
.
localize
(
'
lint.curlyBracketsMustNotBeOmitted
'
,
"
Don't spare curly brackets.
"
),
},
'
javascript.validate.lint.emptyBlocksWithoutComment
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
emptyBlocksWithoutComment
,
'
description
'
:
nls
.
localize
(
'
lint.emptyBlocksWithoutComment
'
,
"
Empty block should have a comment.
"
),
},
'
javascript.validate.lint.comparisonOperatorsNotStrict
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
comparisonOperatorsNotStrict
,
'
description
'
:
nls
.
localize
(
'
lint.comparisonOperatorsNotStrict
'
,
"
Use '!==' and '===' instead of '!=' and '=='.
"
),
},
'
javascript.validate.lint.missingSemicolon
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
missingSemicolon
,
'
description
'
:
nls
.
localize
(
'
lint.missingSemicolon
'
,
"
Missing semicolon.
"
),
},
'
javascript.validate.lint.unknownTypeOfResults
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unknownTypeOfResults
,
'
description
'
:
nls
.
localize
(
'
lint.unknownTypeOfResults
'
,
"
Unexpected output of the 'typeof' operator.
"
),
},
'
javascript.validate.lint.semicolonsInsteadOfBlocks
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
semicolonsInsteadOfBlocks
,
'
description
'
:
nls
.
localize
(
'
lint.semicolonsInsteadOfBlocks
'
,
"
Semicolon instead of block.
"
),
},
'
javascript.validate.lint.functionsInsideLoops
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
functionsInsideLoops
,
'
description
'
:
nls
.
localize
(
'
lint.functionsInsideLoops
'
,
"
Function inside loop.
"
),
},
'
javascript.validate.lint.newOnLowercaseFunctions
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
newOnLowercaseFunctions
,
'
description
'
:
nls
.
localize
(
'
lint.newOnLowercaseFunctions
'
,
"
Function with lowercase name used as constructor.
"
),
},
'
javascript.validate.lint.tripleSlashReferenceAlike
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
tripleSlashReferenceAlike
,
'
description
'
:
nls
.
localize
(
'
lint.tripleSlashReferenceAlike
'
,
"
Looks for mistyped triple-slash references.
"
),
},
'
javascript.validate.lint.unusedVariables
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unusedVariables
,
'
description
'
:
nls
.
localize
(
'
lint.unusedVariables
'
,
"
Unused local variable.
"
),
},
'
javascript.validate.lint.unusedFunctions
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unusedFunctions
,
'
description
'
:
nls
.
localize
(
'
lint.unusedFunctions
'
,
"
Unused local function.
"
),
},
// below rules are changing the severity of some
// TypeScript diagnostics, e.g ignore unknown property
'
javascript.validate.lint.parametersDontMatchSignature
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
parametersDontMatchSignature
,
'
description
'
:
nls
.
localize
(
'
lint.parametersDontMatchSignature
'
,
"
Parameters don't match a function signature
"
),
},
'
javascript.validate.lint.redeclaredVariables
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
redeclaredVariables
,
'
description
'
:
nls
.
localize
(
'
lint.redeclaredVariables
'
,
"
Don't re-declare a variable and change its type.
"
),
},
'
javascript.validate.lint.undeclaredVariables
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
undeclaredVariables
,
'
description
'
:
nls
.
localize
(
'
lint.undeclaredVariables
'
,
"
Don't use an undeclared variable.
"
),
},
'
javascript.validate.lint.unknownProperty
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unknownProperty
,
'
description
'
:
nls
.
localize
(
'
lint.unknownProperty
'
,
"
Don't use an unknown property.
"
),
},
'
javascript.validate.lint.unknownModule
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unknownModule
,
'
description
'
:
nls
.
localize
(
'
lint.unknownModule
'
,
"
Don't require an unknown module.
"
),
},
'
javascript.validate.lint.forcedTypeConversion
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
forcedTypeConversion
,
'
description
'
:
nls
.
localize
(
'
lint.forcedTypeConversion
'
,
"
Don't re-declare a variable type by an assignment.
"
),
},
'
javascript.validate.lint.mixedTypesArithmetics
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
mixedTypesArithmetics
,
'
description
'
:
nls
.
localize
(
'
lint.mixedTypesArithmetics
'
,
"
Only use numbers for arithmetic operations.
"
),
},
'
javascript.validate.lint.primitivesInInstanceOf
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
primitivesInInstanceOf
,
'
description
'
:
nls
.
localize
(
'
lint.primitivesInInstanceOf
'
,
"
Don't use instanceof with primitive types.
"
),
},
'
javascript.validate.lint.newOnReturningFunctions
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
newOnReturningFunctions
,
'
description
'
:
nls
.
localize
(
'
lint.newOnReturningFunctions
'
,
"
Function with return statement used as constructor.
"
),
}
// below rules are changing the severity of some
// TypeScript diagnostics, e.g ignore unknown property
'
javascript.validate.lint.parametersDontMatchSignature
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
parametersDontMatchSignature
,
'
description
'
:
nls
.
localize
(
'
lint.parametersDontMatchSignature
'
,
"
Parameters don't match a function signature
"
),
},
'
javascript.validate.lint.redeclaredVariables
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
redeclaredVariables
,
'
description
'
:
nls
.
localize
(
'
lint.redeclaredVariables
'
,
"
Don't re-declare a variable and change its type.
"
),
},
'
javascript.validate.lint.undeclaredVariables
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
undeclaredVariables
,
'
description
'
:
nls
.
localize
(
'
lint.undeclaredVariables
'
,
"
Don't use an undeclared variable.
"
),
},
'
javascript.validate.lint.unknownProperty
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unknownProperty
,
'
description
'
:
nls
.
localize
(
'
lint.unknownProperty
'
,
"
Don't use an unknown property.
"
),
},
'
javascript.validate.lint.unknownModule
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
unknownModule
,
'
description
'
:
nls
.
localize
(
'
lint.unknownModule
'
,
"
Don't require an unknown module.
"
),
},
'
javascript.validate.lint.forcedTypeConversion
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
forcedTypeConversion
,
'
description
'
:
nls
.
localize
(
'
lint.forcedTypeConversion
'
,
"
Don't re-declare a variable type by an assignment.
"
),
},
'
javascript.validate.lint.mixedTypesArithmetics
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
mixedTypesArithmetics
,
'
description
'
:
nls
.
localize
(
'
lint.mixedTypesArithmetics
'
,
"
Only use numbers for arithmetic operations.
"
),
},
'
javascript.validate.lint.primitivesInInstanceOf
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
primitivesInInstanceOf
,
'
description
'
:
nls
.
localize
(
'
lint.primitivesInInstanceOf
'
,
"
Don't use instanceof with primitive types.
"
),
},
'
javascript.validate.lint.newOnReturningFunctions
'
:
{
'
enum
'
:
[
'
ignore
'
,
'
warning
'
,
'
error
'
],
'
default
'
:
defaults
.
validate
.
lint
.
newOnReturningFunctions
,
'
description
'
:
nls
.
localize
(
'
lint.newOnReturningFunctions
'
,
"
Function with return statement used as constructor.
"
),
}
}
]
});
}
else
{
LanguageExtensions
.
registerLanguage
({
id
:
'
javascript
'
,
extensions
:
[
'
.js
'
,
'
.es6
'
],
firstLine
:
'
^#!.*
\\
bnode
'
,
filenames
:
[
'
jakefile
'
],
aliases
:
[
'
JavaScript
'
,
'
javascript
'
,
'
js
'
],
mimetypes
:
[
'
text/javascript
'
]
});
}
\ No newline at end of file
}
]
});
\ No newline at end of file
src/vs/languages/languages.main.js
浏览文件 @
554004be
...
...
@@ -6,12 +6,10 @@ define([
"
vs/languages/css/common/css.contribution
"
,
"
vs/languages/handlebars/common/handlebars.contribution
"
,
"
vs/languages/html/common/html.contribution
"
,
"
vs/languages/javascript/common/javascript.contribution
"
,
"
vs/languages/markdown/common/markdown.contribution
"
,
"
vs/languages/php/common/php.contribution
"
,
"
vs/languages/plaintext/common/plaintext.contribution
"
,
"
vs/languages/razor/common/razor.contribution
"
,
"
vs/languages/typescript/common/typescript.contribution
"
,
"
vs/languages/less/common/less.contribution
"
,
"
vs/languages/sass/common/sass.contribution
"
],
function
()
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录