mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-21 02:01:43 -05:00
[json] move schema associations to extensions
This commit is contained in:
@@ -2,37 +2,86 @@
|
||||
"name": "javascript",
|
||||
"version": "0.1.0",
|
||||
"publisher": "vscode",
|
||||
"engines": { "vscode": "*" },
|
||||
"engines": {
|
||||
"vscode": "*"
|
||||
},
|
||||
"contributes": {
|
||||
"languages": [{
|
||||
"id": "javascriptreact",
|
||||
"aliases": ["JavaScript React","jsx"],
|
||||
"extensions": [".jsx"],
|
||||
"configuration": "./javascript.configuration.json"
|
||||
},{
|
||||
"id": "javascript",
|
||||
"aliases": ["JavaScript", "javascript", "js"],
|
||||
"extensions": [".js", ".es6"],
|
||||
"filenames": ["jakefile"],
|
||||
"firstLine": "^#!.*\\bnode",
|
||||
"mimetypes": ["text/javascript"]
|
||||
}],
|
||||
"grammars": [{
|
||||
"language": "javascriptreact",
|
||||
"scopeName": "source.jsx",
|
||||
"path": "./syntaxes/JavaScriptReact.tmLanguage"
|
||||
},{
|
||||
"language": "javascript",
|
||||
"scopeName": "source.js",
|
||||
"path": "./syntaxes/JavaScript.tmLanguage"
|
||||
},{
|
||||
// referenced by other grammars
|
||||
"scopeName": "source.js.regexp",
|
||||
"path": "./syntaxes/Regular Expressions (JavaScript).tmLanguage"
|
||||
}],
|
||||
"snippets": [{
|
||||
"language": "javascript",
|
||||
"path": "./snippets/javascript.json"
|
||||
}]
|
||||
"languages": [
|
||||
{
|
||||
"id": "javascriptreact",
|
||||
"aliases": [
|
||||
"JavaScript React",
|
||||
"jsx"
|
||||
],
|
||||
"extensions": [
|
||||
".jsx"
|
||||
],
|
||||
"configuration": "./javascript.configuration.json"
|
||||
},
|
||||
{
|
||||
"id": "javascript",
|
||||
"aliases": [
|
||||
"JavaScript",
|
||||
"javascript",
|
||||
"js"
|
||||
],
|
||||
"extensions": [
|
||||
".js",
|
||||
".es6"
|
||||
],
|
||||
"filenames": [
|
||||
"jakefile"
|
||||
],
|
||||
"firstLine": "^#!.*\\bnode",
|
||||
"mimetypes": [
|
||||
"text/javascript"
|
||||
]
|
||||
}
|
||||
],
|
||||
"grammars": [
|
||||
{
|
||||
"language": "javascriptreact",
|
||||
"scopeName": "source.jsx",
|
||||
"path": "./syntaxes/JavaScriptReact.tmLanguage"
|
||||
},
|
||||
{
|
||||
"language": "javascript",
|
||||
"scopeName": "source.js",
|
||||
"path": "./syntaxes/JavaScript.tmLanguage"
|
||||
},
|
||||
{
|
||||
// referenced by other grammars
|
||||
"scopeName": "source.js.regexp",
|
||||
"path": "./syntaxes/Regular Expressions (JavaScript).tmLanguage"
|
||||
}
|
||||
],
|
||||
"snippets": [
|
||||
{
|
||||
"language": "javascript",
|
||||
"path": "./snippets/javascript.json"
|
||||
}
|
||||
],
|
||||
"jsonValidation": [
|
||||
{
|
||||
"fileMatch": "package.json",
|
||||
"url": "http://json.schemastore.org/project"
|
||||
},
|
||||
{
|
||||
"fileMatch": "bower.json",
|
||||
"url": "http://json.schemastore.org/bower"
|
||||
},
|
||||
{
|
||||
"fileMatch": ".bower.json",
|
||||
"url": "http://json.schemastore.org/bower"
|
||||
},
|
||||
{
|
||||
"fileMatch": ".bowerrc",
|
||||
"url": "http://json.schemastore.org/bowerrc"
|
||||
},
|
||||
{
|
||||
"fileMatch": "jsconfig.json",
|
||||
"url": "./schemas/jsconfig.schema.json"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
79
extensions/javascript/schemas/jsconfig.schema.json
Normal file
79
extensions/javascript/schemas/jsconfig.schema.json
Normal file
@@ -0,0 +1,79 @@
|
||||
{
|
||||
"title": "JSON schema for the JavaScript configuration file",
|
||||
"type": "object",
|
||||
"default": {
|
||||
"compilerOptions": {
|
||||
"target": "ES5"
|
||||
}
|
||||
},
|
||||
"properties": {
|
||||
"compilerOptions": {
|
||||
"type": "object",
|
||||
"description": "Instructs the JavaScript language service how to validate .js files",
|
||||
"properties": {
|
||||
"charset": {
|
||||
"description": "The character set of the input files",
|
||||
"type": "string"
|
||||
},
|
||||
"diagnostics": {
|
||||
"description": "Show diagnostic information.",
|
||||
"type": "boolean"
|
||||
},
|
||||
"locale": {
|
||||
"description": "The locale to use to show error messages, e.g. en-us.",
|
||||
"type": "string"
|
||||
},
|
||||
"mapRoot": {
|
||||
"description": "Specifies the location where debugger should locate map files instead of generated locations",
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
},
|
||||
"module": {
|
||||
"description": "Module code generation to resolve against: 'commonjs', 'amd', 'system', or 'umd'.",
|
||||
"enum": [
|
||||
"commonjs",
|
||||
"amd",
|
||||
"system",
|
||||
"umd"
|
||||
]
|
||||
},
|
||||
"noLib": {
|
||||
"description": "Do not include the default library file (lib.d.ts).",
|
||||
"type": "boolean"
|
||||
},
|
||||
"target": {
|
||||
"description": "Specify ECMAScript target version: 'ES3' (default), 'ES5', or 'ES6' (experimental).",
|
||||
"enum": [
|
||||
"ES3",
|
||||
"ES5",
|
||||
"ES6",
|
||||
"es3",
|
||||
"es5",
|
||||
"es6"
|
||||
],
|
||||
"default": "ES3"
|
||||
},
|
||||
"experimentalDecorators": {
|
||||
"description": "Enables experimental support for ES7 decorators.",
|
||||
"type": "boolean"
|
||||
}
|
||||
}
|
||||
},
|
||||
"files": {
|
||||
"type": "array",
|
||||
"description": "If no 'files' property is present in a jsconfig.json, the language service defaults to including all files the containing directory and subdirectories. When a 'files' property is specified, only those files are included.",
|
||||
"items": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
},
|
||||
"exclude": {
|
||||
"type": "array",
|
||||
"description": "List files and folders that should not be included. This property is not honored when the 'files' property is present.",
|
||||
"items": {
|
||||
"type": "string",
|
||||
"format": "uri"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user