我从https://github.com/zycbob/node-webkit-sqlite3-windows-demo下载了一个演示拉链,解压缩后。我从https://github.com/rogerwang/node-webkit下载了Win32二进制文件存档,解压缩,复制了所有文件,并将它们粘贴到“node-webkit-sqlite3-windows-demo-master”文件夹中。
package.json :
{
"name": "node-webkit-sqlite3-windows-demo",
"main": "main.html",
"window": {
"icon": "",
"toolbar": true,
"width": 1024,
"height": "100%",
"position": "center",
"fullscreen": false,
"frame": true,
"min_width": 900,
"min_height": 600
},
"nodejs": true
}
main.html:
<!DOCTYPE html>
<html>
<head>
<title>Test</title>
<script>
var sqlite3 = require('sqlite3').verbose();
var db = new sqlite3.Database('db');
</script>
</head>
<body>
Test
</body>
</html>
但是当我运行 nw.exe 并出现窗口时,控制台记录
Uncaught Error: The specified procedure could not be found.
path\to\node-webkit-sqlite3-windows-demo-master\node_modules\sqlite3\build\Release\node_sqlite3.node module.js:359
--> Module._extensions[extension](this, filename);
我应该怎样做才能获得有效的离线node-webkit + sqlite演示?