Get Graphviz version from @hpcc-js/wasm synchronously?

@schmoo2k Is it possible to get the Graphviz version from @hpcc-js/wasm synchronously, i.e., without waiting for a promise to resolve? I know I have the graphvizVersion() method, but it returns a promise.

I’m implementing the same method for d3-graphviz and it would be nice (although not crucial) if the user would be able to retrieve the Graphviz version without waiting for the initialization to complete.

Currently its simply returning the PACKAGE_VERSION from config.h, which requires the entire wasm to load, hence the async call (but on the plus side it is never wrong!).

I do have plenty of opportunities to burn it into the JS so could provide a sync version relatively easily?

1 Like

Thanks :slightly_smiling_face:. I’ll settle for the async version for now.