TypeScript 升级到 3.7.2 后的表达式 expected.ts(1109) [英] Expression expected.ts(1109) after TypeScript upgrade to 3.7.2
本文介绍了TypeScript 升级到 3.7.2 后的表达式 expected.ts(1109)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我将 TypeScript 从 3.6.x 升级到 3.7.2.并使用可选链接编写代码.但得到奇怪的错误
I upgraded TypeScript to 3.7.2 from 3.6.x. And write code using optional chaining. But get strange error
表达式expected.ts(1109)
Expression expected.ts(1109)
在 (vim, VSCode) IDE 中,即使构建成功.
in (vim, VSCode) IDE, even when build was successful.
推荐答案
可能是您的编辑器尚未使用 TypeScript 3.7 - 查看是否有选项可以从您的 node_modules 中使用 TSServer 中的 TypeScript 版本.
It could be that your editor isn't using TypeScript 3.7 yet - see if there are options for using the TypeScript version in the TSServer from from your node_modules.
这篇关于TypeScript 升级到 3.7.2 后的表达式 expected.ts(1109)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文