Closed timgoeller closed 4 years ago
Try adding sodium-native
as an external by setting your vue.config.js
to:
module.exports = {
pluginOptions: {
electronBuilder: {
externals: ['sodium-native']
}
}
}
I tried that, and it worked when using sodium-native on itself. It failed with an AssertionError when using the hypercore module however (which relies on the sodium-native module).
Works when adding hypercore to the externals though, so I'll close the issue.
Describe the bug I'm using a module that uses sodium-native in my project. It comes with prebuilds. When starting the project I get an error, that no native build was found for my platform. That's because when it runs the index.js of the node-gyp-build located inside the sodium-native module from the index.js in dist_electron, the dir var in the node-gyp-build index.js file is the dist_electron dir where it won't find the prebuilds. Is there an additional step required to use that module?
To Reproduce Create a new project with vue-cli-plugin-electron-builder, install the hypercore module and import it in background.js.