最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

javascript - How to configure ES6 code inspection - Stack Overflow

programmeradmin1浏览0评论

I've been using PyCharm and really liked it. Recently I switched to ES6 for my javascript code. But PyCharm doesn't seem to like it. For things like => or let it will report syntax error. I tried a lot of things like turning off all inspection and all my effort were in vain. I think I must be missing something silly because normally PyCharm is quite intelligent. What's the trick?

PyCharm version: 2016.1

END OF QUESTION

A bit of rant in the end: I'd really like to get this working. As a long time Vim user, I find it hard to configure Vim for dynamic language such as Javascript and keep making silly mistakes that's time consuming. I've tried VSCode and like the default behaviour but the Vim emulation is sh*t. JetBrain products has the best Vim emulation ever and to me that's a big selling point.

I've been using PyCharm and really liked it. Recently I switched to ES6 for my javascript code. But PyCharm doesn't seem to like it. For things like => or let it will report syntax error. I tried a lot of things like turning off all inspection and all my effort were in vain. I think I must be missing something silly because normally PyCharm is quite intelligent. What's the trick?

PyCharm version: 2016.1

END OF QUESTION

A bit of rant in the end: I'd really like to get this working. As a long time Vim user, I find it hard to configure Vim for dynamic language such as Javascript and keep making silly mistakes that's time consuming. I've tried VSCode and like the default behaviour but the Vim emulation is sh*t. JetBrain products has the best Vim emulation ever and to me that's a big selling point.

Share Improve this question edited May 23, 2016 at 3:47 lang2 asked May 23, 2016 at 3:11 lang2lang2 12k21 gold badges90 silver badges137 bronze badges 3
  • Have you considered using WebStorm instead? It is nearly identical to PyCharm and made by the same pany, but better suited for JavaScript. It supports the exact same plugins as PyCharm. (Including vim) – cyber_dave Commented May 23, 2016 at 3:17
  • I thought PyCharm professional version (trial atm) have all the Javascript support that WebStorm has? – lang2 Commented May 23, 2016 at 3:24
  • @lang2 is right, if you are already using PyCharm, it has what's in WebStorm. I did a webinar for PyCharm on using it for frontend development. – Paul Everitt Commented May 23, 2016 at 11:16
Add a ment  | 

1 Answer 1

Reset to default 12

Just go to Preferences -> Languages & Frameworks -> Javascript and change "JavaScript language version" to ECMAScript 6

发布评论

评论列表(0)

  1. 暂无评论