Eslint fails to parse and red-highlights optional chaining (?.) and nullish coalescing (??) operators

后端 未结 4 754
离开以前
离开以前 2021-02-05 05:26

I am looking for the relevant eslint rules for

  • @babel/plugin-proposal-optional-chaining
  • @babel/plugin-proposal-nullish-coalescing-operator

4条回答
  •  梦谈多话
    2021-02-05 06:05

    Have you tried setting the parser on your eslint config to "babel-eslint"? https://www.npmjs.com/package/babel-eslint It's the recommended parser when using experimental features not supported in eslint yet.

提交回复
热议问题