ipyvega
ipyvega copied to clipboard
Make JS versions more inspectable
It would be nice to provide an easy means for the user to see what version of vega/vega-lite is installed with this package.
Currently (unless I'm mistaken) the only way is to look at package.json, find the vega-embed version, then go to the correct vega-embed release, open its package.json, and look for the vega-lite version there.
I'd love something similar to
>>> import vega
>>> vega.js_versions
{'vega': '4.0.0',
'vega-lite': '2.6.0',
'vega-embed': '3.16.0'}
The trick is to do that without too much manual bookkeeping...
If we had a way to communicate back from the JavaScript to the kernel, this would be easier.
Is there a way to generate files as part of the npm build step?
Or maybe just something like console.logging the versions on load?
It would be nice to if we don't have to add another build step to compile the versions into the python code. Logging the versions on load is trivial.