Pla*_*mer 3 javascript node.js electron
在我的应用中,我需要满负荷运行,检测是否为Electron,然后触发自定义事件。如何实现呢?提前致谢。
我喜欢这个
// check if app is running inside the electron env or browser
var userAgent = navigator.userAgent.toLowerCase();
if (userAgent.indexOf(' electron/') == -1) {
// its not electron
}
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
577 次 |
| 最近记录: |