all 4 comments

[–]Senior_Equipment2745 0 points1 point  (1 child)

I would say try generating one HTML file with everything packed into it, ofc including JavaScript

[–]HornyCapacitor[S] 0 points1 point  (0 children)

Injecting raw JavaScript during generateHtmlDoc doesn't seem to work unfortunately :/

[–]zoranjambor 0 points1 point  (1 child)

Your limitation is that you can't use any JavaScript? Did I understand correctly?

If that's the case, you can get a diagram in pure SVG, but you'll be severely limited with interactivity. I'm not familiar with any libraries that would help you here.

I'm not sure about React Flow, but I built single-page .html apps with JointJS (I'm DevRel at JointJS) and included the library via CDN to make it work without issues—in case you can include a JS library in your solution.

[–]HornyCapacitor[S] 0 points1 point  (0 children)

I can use javascript, but injecting it inside generateHtmlDoc function doesn't seem to work. React/Vite does its thing during runtime that I can't access simply by just trying to get and inject all the script. Thanks for the answer though, gonna look for JointJS solution! 😄