Closed madhuni closed 1 year ago
The setup-sandbox.js
and setup-node-sandbox.js
files are loaded as strings and not through require. Furthermore, the bridge.js
is loaded as string and via require. They should not be transformed as this could have security implications. It is possible to use plugins such as babel-plugin-static-fs
to include the sources of the files where it would be loaded dynamically.
I am facing issue while consuming the
setup-sandbox.js
file via webpack config. The application is failing for the below error:I am suspecting, the
setup-sandbox.js
file returns this object outside of a function which is causing the issue. As per the MDN docs, a return statement should always be inside the function. Wanted to understand how we can bypass this error? Is there any solution for the same in Webpack config?