@faasjs/knex 0.0.4-beta.10 → 0.0.4-beta.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +15 -15
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -44,7 +44,7 @@ FaasJS's sql plugin, base on [Knex](https://knexjs.org/).
|
|
|
44
44
|
|
|
45
45
|
### originKnex
|
|
46
46
|
|
|
47
|
-
▸ **originKnex
|
|
47
|
+
▸ **originKnex**\<`TRecord`, `TResult`\>(`config`): `Knex`\<`TRecord`, `TResult`\>
|
|
48
48
|
|
|
49
49
|
Origin [knex](https://knexjs.org/) instance.
|
|
50
50
|
|
|
@@ -59,17 +59,17 @@ Origin [knex](https://knexjs.org/) instance.
|
|
|
59
59
|
|
|
60
60
|
| Name | Type |
|
|
61
61
|
| :------ | :------ |
|
|
62
|
-
| `config` | `string` \| `Config
|
|
62
|
+
| `config` | `string` \| `Config`\<`any`\> |
|
|
63
63
|
|
|
64
64
|
#### Returns
|
|
65
65
|
|
|
66
|
-
`Knex
|
|
66
|
+
`Knex`\<`TRecord`, `TResult`\>
|
|
67
67
|
|
|
68
68
|
___
|
|
69
69
|
|
|
70
70
|
### query
|
|
71
71
|
|
|
72
|
-
▸ **query
|
|
72
|
+
▸ **query**\<`TName`\>(`table`): `OriginKnex.QueryBuilder`\<`OriginKnex.TableType`\<`TName`\>, \{ `_aliases`: {} ; `_base`: `OriginKnex.ResolveTableType`\<`OriginKnex.TableType`\<`TName`\>, ``"base"``\> ; `_hasSelection`: ``false`` ; `_intersectProps`: {} ; `_keys`: `never` ; `_single`: ``false`` ; `_unionProps`: `never` }[]\>
|
|
73
73
|
|
|
74
74
|
#### Type parameters
|
|
75
75
|
|
|
@@ -85,9 +85,9 @@ ___
|
|
|
85
85
|
|
|
86
86
|
#### Returns
|
|
87
87
|
|
|
88
|
-
`OriginKnex.QueryBuilder
|
|
88
|
+
`OriginKnex.QueryBuilder`\<`OriginKnex.TableType`\<`TName`\>, \{ `_aliases`: {} ; `_base`: `OriginKnex.ResolveTableType`\<`OriginKnex.TableType`\<`TName`\>, ``"base"``\> ; `_hasSelection`: ``false`` ; `_intersectProps`: {} ; `_keys`: `never` ; `_single`: ``false`` ; `_unionProps`: `never` }[]\>
|
|
89
89
|
|
|
90
|
-
▸ **query
|
|
90
|
+
▸ **query**\<`TName`, `TResult`\>(`table`): `OriginKnex.QueryBuilder`\<`TName`, `TResult`\>
|
|
91
91
|
|
|
92
92
|
#### Type parameters
|
|
93
93
|
|
|
@@ -104,13 +104,13 @@ ___
|
|
|
104
104
|
|
|
105
105
|
#### Returns
|
|
106
106
|
|
|
107
|
-
`OriginKnex.QueryBuilder
|
|
107
|
+
`OriginKnex.QueryBuilder`\<`TName`, `TResult`\>
|
|
108
108
|
|
|
109
109
|
___
|
|
110
110
|
|
|
111
111
|
### raw
|
|
112
112
|
|
|
113
|
-
▸ **raw
|
|
113
|
+
▸ **raw**\<`TResult`\>(`sql`, `bindings?`): `Promise`\<`TResult`\>
|
|
114
114
|
|
|
115
115
|
#### Type parameters
|
|
116
116
|
|
|
@@ -127,13 +127,13 @@ ___
|
|
|
127
127
|
|
|
128
128
|
#### Returns
|
|
129
129
|
|
|
130
|
-
`Promise
|
|
130
|
+
`Promise`\<`TResult`\>
|
|
131
131
|
|
|
132
132
|
___
|
|
133
133
|
|
|
134
134
|
### transaction
|
|
135
135
|
|
|
136
|
-
▸ **transaction
|
|
136
|
+
▸ **transaction**\<`TResult`\>(`scope`, `config?`, `options?`): `Promise`\<`TResult` \| `void`\>
|
|
137
137
|
|
|
138
138
|
#### Type parameters
|
|
139
139
|
|
|
@@ -145,20 +145,20 @@ ___
|
|
|
145
145
|
|
|
146
146
|
| Name | Type |
|
|
147
147
|
| :------ | :------ |
|
|
148
|
-
| `scope` | (`trx`: `Transaction
|
|
148
|
+
| `scope` | (`trx`: `Transaction`\<`any`, `any`\>) => `void` \| `Promise`\<`TResult`\> |
|
|
149
149
|
| `config?` | `TransactionConfig` |
|
|
150
150
|
| `options?` | `Object` |
|
|
151
|
-
| `options.trx?` | `Transaction
|
|
151
|
+
| `options.trx?` | `Transaction`\<`any`, `any`[]\> |
|
|
152
152
|
|
|
153
153
|
#### Returns
|
|
154
154
|
|
|
155
|
-
`Promise
|
|
155
|
+
`Promise`\<`TResult` \| `void`\>
|
|
156
156
|
|
|
157
157
|
___
|
|
158
158
|
|
|
159
159
|
### useKnex
|
|
160
160
|
|
|
161
|
-
▸ **useKnex**(`config?`): `UseifyPlugin
|
|
161
|
+
▸ **useKnex**(`config?`): `UseifyPlugin`\<[`Knex`](classes/Knex.md)\>
|
|
162
162
|
|
|
163
163
|
#### Parameters
|
|
164
164
|
|
|
@@ -168,4 +168,4 @@ ___
|
|
|
168
168
|
|
|
169
169
|
#### Returns
|
|
170
170
|
|
|
171
|
-
`UseifyPlugin
|
|
171
|
+
`UseifyPlugin`\<[`Knex`](classes/Knex.md)\>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@faasjs/knex",
|
|
3
|
-
"version": "0.0.4-beta.
|
|
3
|
+
"version": "0.0.4-beta.11",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -21,9 +21,9 @@
|
|
|
21
21
|
"dist"
|
|
22
22
|
],
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@faasjs/deep_merge": "0.0.4-beta.
|
|
25
|
-
"@faasjs/func": "0.0.4-beta.
|
|
26
|
-
"@faasjs/logger": "0.0.4-beta.
|
|
24
|
+
"@faasjs/deep_merge": "0.0.4-beta.11",
|
|
25
|
+
"@faasjs/func": "0.0.4-beta.11",
|
|
26
|
+
"@faasjs/logger": "0.0.4-beta.11"
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"knex": "*"
|