Add externs file for Node's use of promise_sqlite.

This commit is contained in:
Richard Newman 2016-09-14 16:05:42 -07:00
parent d178c53dcb
commit 330433a45c
2 changed files with 15 additions and 0 deletions

View file

@ -29,6 +29,7 @@
:compiler :compiler
{ {
:elide-asserts true :elide-asserts true
:externs ["src/node/externs.js"]
:hashbang false :hashbang false
:language-in :ecmascript5 :language-in :ecmascript5
:language-out :ecmascript5 :language-out :ecmascript5
@ -76,6 +77,7 @@
{:source-paths ["src/node"] {:source-paths ["src/node"]
:compiler :compiler
{ {
:externs ["src/node/externs.js"]
:language-in :ecmascript5 :language-in :ecmascript5
:language-out :ecmascript5 :language-out :ecmascript5
:output-dir "target/advanced" :output-dir "target/advanced"

13
src/node/externs.js Normal file
View file

@ -0,0 +1,13 @@
var sqlite = {};
sqlite.DB = {};
/**
* @return {Promise}
*/
sqlite.DB.open = function (path, options) {};
var DBVal = {};
DBVal.run = function (sql, bindings) {};
DBVal.close = function () {};
DBVal.each = function (sql, bindings, cb) {};