`distribution` also seems not to work for Node, pr...
# javascript
r
distribution
also seems not to work for Node, probably for related reasons
t
What about such configuration?
Copy code
js {
    useCommonJs()
    browser {
        webpackTask {
            output.globalObject = "this"
        }
    }
    binaries.executable()
}
In browser global object -
window
v
Or you use ncc like I do it in https://github.com/Vampire/setup-wsl/
r
I managed to get it working using config like @turansky suggested, although I had to add a custom webpack config file with
config.target = 'node';
v
Sure, both options work