Nullish Coalescing operator (??) support for upcoming TypeScript release

TypeScript 3.7.0-beta

WebStorm 2019.2.2

11 comments
Comment actions Permalink

https://youtrack.jetbrains.com/issue/WEB-41494 is fixed i n 2019.3

Nullish operator is correctly highlighted for me in 2019.3 EAP if the TypeScript language service is off:

By assertion expressions, do you mean https://github.com/microsoft/TypeScript/pull/32695? They are also supported in 2019.3 (https://youtrack.jetbrains.com/issue/WEB-41436)

 

1
Comment actions Permalink

Oh, crap... Yes, you're right Elena.

I had `Automatic TSLint configuration` in settings. After replaced with the `Manual...` one everything works fine. One idea I have now - TSLint version was updated while WebStorm was running, so it used previously installed version and show error. With update config, I triggered the restart of TSList and now it works.

Thank you very much :)

1
Comment actions Permalink

Nullish operator is supported since the upcoming 2019.3.

Please try 2019.3 EAP (https://www.jetbrains.com/webstorm/nextversion) - does the issue persist?

1
Comment actions Permalink

As well as assertion expressions; I assume implementing beta features can be a waste of resources in case something changes before release, although for JavaScript nullish coalescing was implemented a year ago: https://youtrack.jetbrains.com/issue/WEB-32660

Can we have some clarification on how the process usually goes?

0
Comment actions Permalink

Our project just updated to TS@3.7.2 and I can see such error:

I'm using WebStorm 2019.3 EAP
Build #WS-193.4932.10, built on October 30, 2019
Runtime version: 11.0.4+10-b520.2 x86_64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o
macOS 10.15
GC: G1 Young Generation, G1 Old Generation
Memory: 4096M
Registry:
Non-Bundled Plugins: com.emberjs, com.intellij.ideolog, quokka.js

0
Comment actions Permalink

The only error in your screenshot comes from TSLint and doesn't look related to nullish operator; please hover over the operator and attach a screenshot of the error message

0
Comment actions Permalink

Nullish coalescing operator is incorrectly highlighted for me too.

I am using Typescript 3.7.2(and it shows this version as well in the typescript tab). The compilation is also working fine but the editor show this error

Since this feature is officially released, it should be fixed in the editor now

0
Comment actions Permalink

Works on 2.4 for me.


Now waiting on asserts release:)

0
Comment actions Permalink

It works!

Thanks Elena!

0
Comment actions Permalink

Something needs to be done on older versions.. 2019.1.4 is not fixed :(

0
Comment actions Permalink

we don't plan to patch old versions to make them compatible with each and every new Typescript feature, sorry

0

Please sign in to leave a comment.