I am just trying out electron and have a very simple app that should load a webpage when running npm start
var app = require('app');
var BrowserWindow = require('browser-window');
app.on('ready', function() {
var window = new BrowserWindow({
height : 750,
width: 1000,
frame: false
});
window.loadUrl('https://google.com');
});
But I get the error : TypeError: core.require is not a function
The commands I run are:
npm install electron-prebuilt
npm install app
npm install browser-window
My package.json is:
{
"name": "SimpleWeb",
"version" : "0.0.2",
"main" : "main.js",
"scripts" : {
"start" : "electron ."
}
}
I am not sure why I am getting the crash - could someone help me out here :-)
via Jeff Kranenburg
No comments:
Post a Comment