<commit_before>'use strict';

const electron = require('electron'); 
const {app, BrowserWindow, ipcMain} = electron; 

console.log('Electron: \n' + electron);          // TODO: ???

let win;

function createWindow() {
    win = new BrowserWindow({width: 800, height: 600});
    win.on('closed', () => {
        win = null; 
    });
    win.loadURL(`file://${__dirname}/index.html`);
}

app.on('ready', () => {console.log('Starting!'); createWindow();});
app.on('window-all-closed', () => {
    if (process.platform != 'darwin') {
        app.quit();
    }
});
app.on('activate', () => {
    if (window === null) {
        createWindow();
    }
});

ipcMain.on('asynchronous-message', (event, arg) => {
    console.log('Event: ' + event);
    for (let prop in event) {
        console.log(prop + ': ' + event[prop]);
    }
    console.log('Arg: ' + arg);
    for (let prop in arg) {
        console.log(prop + ': ' + arg[prop]); 
    }
    event.sender.send('asynchronous-message',
                 {type: 'ACK_BUFFER_KEY_PRESS',
                  key: arg.key});
});
<commit_msg>Flesh out view-level structure.<commit_after>'use strict';

const electron = require('electron'); 
const {app, BrowserWindow, ipcMain} = electron; 

console.log('Electron: \n' + electron);          // TODO: ???

let win;

function createWindow() {
    win = new BrowserWindow({width: 800, height: 600});
    win.on('closed', () => {
        win = null; 
    });
    win.loadURL(`file://${__dirname}/index.html`);
}

app.on('ready', () => {console.log('Starting!'); createWindow();});
app.on('window-all-closed', () => {
    if (process.platform != 'darwin') {
        app.quit();
    }
});
app.on('activate', () => {
    if (window === null) {
        createWindow();
    }
});


{'fraction_non_alphanumeric': 0.2161547212741752, 'fraction_numerical': 0.006825938566552901, 'mean_word_length': 2.782795698924731, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2413708', 'n_tokens_mistral': 607, 'n_tokens_neox': 575, 'n_words': 111}