Skip to content

Instantly share code, notes, and snippets.

@yoannmoinet
Last active November 7, 2017 08:23
Show Gist options
  • Save yoannmoinet/38fc03c9ca275bb934841fe438a09644 to your computer and use it in GitHub Desktop.
Save yoannmoinet/38fc03c9ca275bb934841fe438a09644 to your computer and use it in GitHub Desktop.
Activate plugins in Electron
import { app } from 'electron';
import path from 'path';
import {
WIDEVINE_PATH,
WIDEVINE_VERSION,
PEPPERFLASH_PATH,
PEPPERFLASH_VERSION
} from './config';
app.commandLine.appendSwitch('widevine-cdm-path', path.join(__dirname, WIDEVINE_PATH));
app.commandLine.appendSwitch('widevine-cdm-version', WIDEVINE_VERSION);
app.commandLine.appendSwitch('ppapi-flash-path', path.join(__dirname, PEPPERFLASH_PATH));
app.commandLine.appendSwitch('ppapi-flash-version', PEPPERFLASH_VERSION);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment