To disable the default set of globals, create a jsconfig.json file at the root of your project with the content:{ "compilerOptions": { "lib": ["es6"] }}这会阻止 VSCode 用于 JavaScript IntelliSense 的 TypeScript 服务自动包含有关 DOM api 的信息.This prevents the TypeScript service that VSCode uses for JavaScript IntelliSense from automatically including information about the DOM api.您可以阅读所有可用的libTypeScript 文档中的配置选项.You can read about all the avalible lib configuration options in the TypeScript documentation. 这篇关于降低 javascript 智能感知的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云! 08-19 11:19