Slide 13
Slide 13 text
࠷খͷΞϓϦέʔγϣϯ
1 {
2 name: MinimalApp,
3 version: 0.0.1,
4 main: main.js,
5 devDependencies: {
6 electron-prebuilt: ^0.34.2
7 }
8 }
1
2
3
4
5 Minimal App
6
7
8 Hello, world!!
9
10
1 'use strict';
2 const app = require('app');
3 const BrowserWindow
4 = require('browser-window');
5 const path = require('path');
6
7 app.on('ready', () => {
8 let win = new BrowserWindow(
9 {width: 800, height: 600}
10 );
11 win.on('closed', () => {
12 win = null;
13 app.quit();
14 });
15 const url = 'file://'
16 + path.join(__dirname, 'index.html');
17 win.loadUrl(url);
18 });
NBJOKT QBDLBHFKTPO
JOEFYIUNM