Open we-zhang opened 8 years ago
What I do is loading the third party library as text (with webpack, in my case) and inject it in the wrapper code. You can't normally access the DOM or window object, though, at least in the browser, so be prepared to mock stuff :)
And I guess this is a duplicate of https://github.com/asvd/jailed/issues/23
If the loaded code in sandbox requires some dependency/lib, is there any way to import the libs to sandbox for the code to use?