vega-lite-api icon indicating copy to clipboard operation
vega-lite-api copied to clipboard

Output Typescript Code

Open kanitw opened this issue 5 years ago • 7 comments

The code for generating the API could still be Javascript, since it only affects us.

However, a lot of people may want to use the output JS API in Typescript projects (which offer superior autocompletion than vanilla JS). Thus, it might be worth making sure that our output code is in TS.

cc: @domoritz

kanitw avatar May 13 '19 18:05 kanitw

yeah, I'd be curious to see TS setup for this lib api too, not just for JS webapps vega viz gen. I prefer to code in TS too!

What's required to make this lib work in & provide proper TS api? Think ahead! cc @domoritz :)

RandomFractals avatar May 13 '19 19:05 RandomFractals

@kanitw @jheer & @domoritz do you guys still plan to work on the companion https://github.com/vega/vega-lite-to-api repo?

I think it would be great to be able to have a library that generates this vega-lite api code from Vega specs.

I'd love to add that feature to the Vega Viewer 📈 when you are ready for it ...

https://github.com/RandomFractals/vscode-vega-viewer

RandomFractals avatar Aug 19 '19 09:08 RandomFractals

@RandomFractals we will get back to it that some points, but currently doesn't have time to finish it.

kanitw avatar Aug 19 '19 22:08 kanitw

:( ok

RandomFractals avatar Aug 20 '19 11:08 RandomFractals

any ETA on this? if you don't think you'll get to it this year, I'd rather close that issue in my repo.

RandomFractals avatar Oct 11 '19 04:10 RandomFractals

We’re more than happy to accept a PR for this feature. I don’t think we have a pressing need for this from our side before the end of the year.

domoritz avatar Oct 11 '19 16:10 domoritz

I'd have to play a bit with this api library to see what needs to be done for the TS code gen. I doubt I'll get to it this year also, but let's keep this open. I think it would be a great feature to have eventually.

RandomFractals avatar Oct 13 '19 07:10 RandomFractals