问题
In order to get jQuery to load and function correctly in a HTML page I was opening in Electron (formerly Atom Shell), I had to disable Node integration when creating the BrowserWindow
in my main.js
file.
Can someone please tell me what setting node-integration: false
will keep me from being able to do that I would normally be able to do had I not disabled it?
回答1:
Setting node-integration to false will disable node.js in the renderer process - i.e. your app can only do what a web browser will do. Instead of doing this, use Zepto.js which is compatible with Electron and has the same API.
来源:https://stackoverflow.com/questions/29860278/whats-the-outcome-of-setting-node-integration-to-false-when-creating-a-new-brow