小编sar*_*his的帖子

电子应用程序获取异常同时需要SQLITE3

的package.json

"name": "billingapp",
"version": "1.0.0",
"description": "",
"main": "index.js",
"scripts": {
"rebuild": "electron-rebuild -f -w billingapp"
},
"author": "S Kundu",
"license": "ISC",
"dependencies": {
"electron": "^1.7.11",
"sqlite3": "^3.1.13"
}
"devDependencies": {
"electron-rebuild": "^1.7.3"
}
Run Code Online (Sandbox Code Playgroud)

index.js

const electron  = require('electron');
const path      = require('path');
const url       = require('url');
var sqlite3 = require('sqlite3').verbose();
var db = new sqlite3.Database(path.join(__dirname, 'sample.db'));

const {app, BrowserWindow, Menu, ipcMain} = electron;

let mainWindow;

app.on('ready', function(){


// Create the login window
mainWindow = new BrowserWindow({
  resizable: true,
  fullscreen: …
Run Code Online (Sandbox Code Playgroud)

javascript sqlite electron

11
推荐指数
1
解决办法
523
查看次数

标签 统计

electron ×1

javascript ×1

sqlite ×1