提交 a323b399 编写于 作者: E Erich Gamma

dynamically refresh the view when the npm.exclude setting changes

上级 49323b37
......@@ -15,10 +15,16 @@ let taskProvider: vscode.Disposable | undefined;
export async function activate(context: vscode.ExtensionContext): Promise<void> {
taskProvider = registerTaskProvider(context);
registerExplorer(context);
const treeDataProvider = registerExplorer(context);
configureHttpRequest();
vscode.workspace.onDidChangeConfiguration(() => {
vscode.workspace.onDidChangeConfiguration((e) => {
configureHttpRequest();
if (e.affectsConfiguration('npm.exclude')) {
invalidateScriptsCache();
if (treeDataProvider) {
treeDataProvider.refresh();
}
}
});
context.subscriptions.push(addJSONProviders(httpRequest.xhr));
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册