I was trying to implent mxgraph in my next.js app but importing library throws error.
Is there any way to solve Reference Error if certain library doesn't handle undefined window or navigator?
1 |import mx from "mxgraph";
2 |
> 3 | const mxgraph = mx({
| ^
4 | mxBasePath: "/assets/mxgraph",
5 | });
Here's my repo