cljs-dev

ClojureScript compiler & std lib dev, https://clojurescript.org/community/dev
cfleming 2020-11-03T22:35:35.013800Z

I’m playing around with the Google Closure JS parser, because I’m considering replacing the JS parser in Cursive with it. However doing some tests with it it seems like it doesn’t support ES6 decorators - does anyone know if that’s the case? I’d be surprised since AFAICT the idea is that it should be able to parse/handle anything, but I might be wrong about that.

thheller 2020-11-03T22:37:35.014300Z

aren't decorators still just a proposal? don't think they ever actually made it into es6?

thheller 2020-11-03T22:41:37.015700Z

otherwise the parser is updated fairly regularly with most features as long as they are on some standard level

cfleming 2020-11-03T22:41:38.015800Z

I’m not sure, I must admit.

cfleming 2020-11-03T22:41:59.016200Z

Ok, thanks.

thheller 2020-11-03T22:42:25.016600Z

most recent thing they implement is the optional chaining stuff

thheller 2020-11-03T22:42:41.016900Z

foo?.bar etc

cfleming 2020-11-03T22:43:08.017600Z

Ah, ok. So presumably they’ll implement things like decorators if they become standard?

thheller 2020-11-03T22:43:21.017900Z

I'd assume so yes

thheller 2020-11-03T22:43:48.018200Z

https://github.com/tc39/proposal-decorators looks like its still just a proposal

thheller 2020-11-03T22:44:32.018700Z

typescript has them I believe but typescript support is limited in gcc

cfleming 2020-11-03T22:45:53.020100Z

I think they have some support for parsing, and also converting TS types to Closure ones - presumably so they can use type definition files for third party libs.

lilactown 2020-11-03T23:24:40.021800Z

Indeed, tsickle is quite cool

lilactown 2020-11-03T23:25:19.022Z

https://github.com/angular/tsickle

lilactown 2020-11-03T23:25:51.022800Z

Not sure what the status of actual native support for TS is in GCC