Electron's documentation (for example http://electron.atom.io/docs/api/browser-window/) says to import some features using a destructuring statement:
const {BrowserWindow} = require('electron')
This works when running the code in Electron but Jasmine and Visual Studio* claim that the "{" is a syntax error.
What is the correct usage?
*The code is actually written in Typescript (1.8 targeting ES2015) but the transpiled code in JS is identical in this case.