vscode 插件入门指南 (opens new window)
package.json
看做了什么enable
packageManager
alwaysShowStatus
nodePath
options
trace.server
run
autoFixOnSave
quiet
validate
executeAutofix
showOutputChannel
createConfig
enable/disable
client + server
vscode.workspace.onDidOpenTextDocument
vscode.workspace.onDidChangeConfiguration
StatusBar
> command.showOutputChannel
client
context.subscriptions.push(vscode.commands.registerCommand('command name', func))
vscode.workspace.onDidChangeConfiguration
vscode.workspace.onDidChangeWorkspaceFolders
eslint.provideLintTask
,创建并执行 .vscode.tasks.json
中的 eslint
任务autoFixOnSave
过程eslint.executeAutofix
(根据指令执行)documents.onWillSaveWaitUntil
(根据配置执行)client.sendRequest
用 command
的值做标识createConnection().onRequest
注册请求,通过数据中的 command
执行相应任务TextEdit.replace
WorkspaceChange.getTextEditChange().add(TextEdit[])
documents.onWillSaveWaitUntil
返回 TextEdit[]
← Vetur cache-loader →