-
Notifications
You must be signed in to change notification settings - Fork 241
/
Copy pathindex.js
38 lines (27 loc) · 787 Bytes
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
'use strict';
const { Schema } = require('./lib/schema');
const AbstractClass = require('./lib/model.js');
module.exports = {
Schema,
AbstractClass,
// deprecated api
loadSchema: function(filename, settings, compound) {
return require('./legacy-compound-schema-loader')(Schema, filename, settings, compound);
},
init: function init(compound) {
return require('./legacy-compound-init')(compound, Schema, AbstractClass);
},
get BaseSQL() {
return require('./lib/sql');
},
get version() {
return require(
process.versions.node >= '6'
? './package.json'
: '../package.json'
).version;
},
get test() {
return require('./test/common_test');
}
};