added support for Electron platform

This commit is contained in:
pwlin 2020-07-26 19:24:37 +01:00
parent 3a6047c7c1
commit 5c9b7259aa
2 changed files with 11 additions and 1 deletions

View File

@ -61,7 +61,7 @@ Opens a file
- Android 4.4+
- iOS 9+
- Windows
- WP8
- Electron
### Quick Examples
Open an APK install dialog:
@ -90,6 +90,8 @@ cordova.plugins.fileOpener2.open(
);
```
__Note on Electron:__ Do not forget to enable Node.js in your app by adding `"nodeIntegration": true` to `platforms/electron/platform_www/cdv-electron-settings.json` file, See [Cordova-Electron documentation](https://cordova.apache.org/docs/en/latest/guide/platforms/electron/index.html#customizing-the-application's-window-options).
### Market place installation
Install From Market: to install an APK from a market place, such as Google Play or the App Store, you can use an `<a>` tag in combination with the `market://` protocol:

View File

@ -86,4 +86,12 @@
<runs/>
</js-module>
</platform>
<!-- electron -->
<platform name="electron">
<js-module src="src/electron/FileOpener2.js" name="fileOpener2">
<merges target="" />
</js-module>
</platform>
</plugin>