graphile-settings 4.20.2 → 4.21.1
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/esm/plugins/enable-all-filter-columns.d.ts +1 -1
- package/esm/plugins/enable-all-filter-columns.js +1 -1
- package/esm/presets/constructive-preset.d.ts +2 -2
- package/esm/presets/constructive-preset.js +10 -8
- package/package.json +19 -19
- package/plugins/enable-all-filter-columns.d.ts +1 -1
- package/plugins/enable-all-filter-columns.js +1 -1
- package/presets/constructive-preset.d.ts +2 -2
- package/presets/constructive-preset.js +10 -8
|
@@ -38,7 +38,7 @@ import type { GraphileConfig } from 'graphile-config';
|
|
|
38
38
|
* and adds `+attribute:filterBy` and `+attribute:orderBy` back to ALL columns, regardless of index status.
|
|
39
39
|
*
|
|
40
40
|
* This means:
|
|
41
|
-
* - All columns will appear in the connection filter's
|
|
41
|
+
* - All columns will appear in the connection filter's `where` argument
|
|
42
42
|
* - All columns will appear in the connection's orderBy enum
|
|
43
43
|
* - Developers can filter and sort by any column
|
|
44
44
|
* - It's the developer's/DBA's responsibility to add indexes for frequently filtered/sorted columns
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
* and adds `+attribute:filterBy` and `+attribute:orderBy` back to ALL columns, regardless of index status.
|
|
38
38
|
*
|
|
39
39
|
* This means:
|
|
40
|
-
* - All columns will appear in the connection filter's
|
|
40
|
+
* - All columns will appear in the connection filter's `where` argument
|
|
41
41
|
* - All columns will appear in the connection's orderBy enum
|
|
42
42
|
* - Developers can filter and sort by any column
|
|
43
43
|
* - It's the developer's/DBA's responsibility to add indexes for frequently filtered/sorted columns
|
|
@@ -31,8 +31,8 @@ import type { GraphileConfig } from 'graphile-config';
|
|
|
31
31
|
*
|
|
32
32
|
* RELATION FILTERS:
|
|
33
33
|
* - Enabled via connectionFilterRelations: true
|
|
34
|
-
* - Forward: filter child by parent (e.g. allOrders(
|
|
35
|
-
* - Backward: filter parent by children (e.g. allClients(
|
|
34
|
+
* - Forward: filter child by parent (e.g. allOrders(where: { clientByClientId: { name: { startsWith: "Acme" } } }))
|
|
35
|
+
* - Backward: filter parent by children (e.g. allClients(where: { ordersByClientId: { some: { total: { greaterThan: 1000 } } } }))
|
|
36
36
|
*
|
|
37
37
|
* USAGE:
|
|
38
38
|
* ```typescript
|
|
@@ -41,8 +41,8 @@ import { getBucketProvisionerConnection } from '../bucket-provisioner-resolver';
|
|
|
41
41
|
*
|
|
42
42
|
* RELATION FILTERS:
|
|
43
43
|
* - Enabled via connectionFilterRelations: true
|
|
44
|
-
* - Forward: filter child by parent (e.g. allOrders(
|
|
45
|
-
* - Backward: filter parent by children (e.g. allClients(
|
|
44
|
+
* - Forward: filter child by parent (e.g. allOrders(where: { clientByClientId: { name: { startsWith: "Acme" } } }))
|
|
45
|
+
* - Backward: filter parent by children (e.g. allClients(where: { ordersByClientId: { some: { total: { greaterThan: 1000 } } } }))
|
|
46
46
|
*
|
|
47
47
|
* USAGE:
|
|
48
48
|
* ```typescript
|
|
@@ -92,9 +92,11 @@ export const ConstructivePreset = {
|
|
|
92
92
|
],
|
|
93
93
|
/**
|
|
94
94
|
* Disable PostGraphile core's condition argument entirely.
|
|
95
|
-
* All filtering now lives under the `
|
|
96
|
-
* graphile-connection-filter plugin
|
|
97
|
-
*
|
|
95
|
+
* All filtering now lives under the `where` argument via our v5-native
|
|
96
|
+
* graphile-connection-filter plugin (which renames the default `filter`
|
|
97
|
+
* argument to `where` via `connectionFilterArgumentName: 'where'`).
|
|
98
|
+
* Search, BM25, pgvector, and PostGIS filter fields all hook into
|
|
99
|
+
* `isPgConnectionFilter` instead of `isPgCondition`.
|
|
98
100
|
*/
|
|
99
101
|
disablePlugins: [
|
|
100
102
|
'PgConditionArgumentPlugin',
|
|
@@ -103,7 +105,7 @@ export const ConstructivePreset = {
|
|
|
103
105
|
/**
|
|
104
106
|
* Connection Filter Plugin Configuration
|
|
105
107
|
*
|
|
106
|
-
* These options control what fields appear in the `
|
|
108
|
+
* These options control what fields appear in the `where` argument on connections.
|
|
107
109
|
* Our v5-native graphile-connection-filter plugin controls relation filters via the
|
|
108
110
|
* `connectionFilterRelations` option passed to ConnectionFilterPreset().
|
|
109
111
|
*
|
|
@@ -129,13 +131,13 @@ export const ConstructivePreset = {
|
|
|
129
131
|
/**
|
|
130
132
|
* connectionFilterLogicalOperators: true (default)
|
|
131
133
|
* Keeps `and`, `or`, `not` operators for combining filter conditions.
|
|
132
|
-
* Example:
|
|
134
|
+
* Example: where: { or: [{ name: { eq: "foo" } }, { name: { eq: "bar" } }] }
|
|
133
135
|
*/
|
|
134
136
|
connectionFilterLogicalOperators: true,
|
|
135
137
|
/**
|
|
136
138
|
* connectionFilterArrays: true (default)
|
|
137
139
|
* Allows filtering on PostgreSQL array columns.
|
|
138
|
-
* Example:
|
|
140
|
+
* Example: where: { tags: { contains: ["important"] } }
|
|
139
141
|
*/
|
|
140
142
|
connectionFilterArrays: true,
|
|
141
143
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "graphile-settings",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.21.1",
|
|
4
4
|
"author": "Constructive <developers@constructive.io>",
|
|
5
5
|
"description": "graphile settings",
|
|
6
6
|
"main": "index.js",
|
|
@@ -30,37 +30,37 @@
|
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@aws-sdk/client-s3": "^3.1009.0",
|
|
33
|
-
"@constructive-io/bucket-provisioner": "^0.
|
|
34
|
-
"@constructive-io/graphql-env": "^3.
|
|
35
|
-
"@constructive-io/graphql-types": "^3.
|
|
36
|
-
"@constructive-io/s3-streamer": "^2.
|
|
37
|
-
"@constructive-io/upload-names": "^2.
|
|
33
|
+
"@constructive-io/bucket-provisioner": "^0.3.0",
|
|
34
|
+
"@constructive-io/graphql-env": "^3.6.0",
|
|
35
|
+
"@constructive-io/graphql-types": "^3.5.0",
|
|
36
|
+
"@constructive-io/s3-streamer": "^2.18.0",
|
|
37
|
+
"@constructive-io/upload-names": "^2.11.0",
|
|
38
38
|
"@dataplan/json": "1.0.0",
|
|
39
39
|
"@dataplan/pg": "1.0.0",
|
|
40
40
|
"@graphile-contrib/pg-many-to-many": "2.0.0-rc.2",
|
|
41
|
-
"@pgpmjs/logger": "^2.
|
|
42
|
-
"@pgpmjs/types": "^2.
|
|
41
|
+
"@pgpmjs/logger": "^2.6.0",
|
|
42
|
+
"@pgpmjs/types": "^2.22.0",
|
|
43
43
|
"@pgsql/quotes": "^17.1.0",
|
|
44
44
|
"cors": "^2.8.6",
|
|
45
45
|
"express": "^5.2.1",
|
|
46
46
|
"grafast": "1.0.0",
|
|
47
47
|
"grafserv": "1.0.0",
|
|
48
|
-
"graphile-bucket-provisioner-plugin": "0.
|
|
48
|
+
"graphile-bucket-provisioner-plugin": "0.3.0",
|
|
49
49
|
"graphile-build": "5.0.0",
|
|
50
50
|
"graphile-build-pg": "5.0.0",
|
|
51
51
|
"graphile-config": "1.0.0",
|
|
52
|
-
"graphile-connection-filter": "^1.
|
|
53
|
-
"graphile-postgis": "^2.
|
|
54
|
-
"graphile-presigned-url-plugin": "^0.
|
|
55
|
-
"graphile-search": "^1.
|
|
56
|
-
"graphile-sql-expression-validator": "^2.
|
|
57
|
-
"graphile-upload-plugin": "^2.
|
|
52
|
+
"graphile-connection-filter": "^1.5.0",
|
|
53
|
+
"graphile-postgis": "^2.11.1",
|
|
54
|
+
"graphile-presigned-url-plugin": "^0.5.0",
|
|
55
|
+
"graphile-search": "^1.7.0",
|
|
56
|
+
"graphile-sql-expression-validator": "^2.7.0",
|
|
57
|
+
"graphile-upload-plugin": "^2.6.0",
|
|
58
58
|
"graphile-utils": "5.0.0",
|
|
59
59
|
"graphql": "16.13.0",
|
|
60
60
|
"inflekt": "^0.7.1",
|
|
61
61
|
"lru-cache": "^11.2.7",
|
|
62
62
|
"pg": "^8.20.0",
|
|
63
|
-
"pg-query-context": "^2.
|
|
63
|
+
"pg-query-context": "^2.10.0",
|
|
64
64
|
"pg-sql2": "5.0.0",
|
|
65
65
|
"postgraphile": "5.0.0",
|
|
66
66
|
"request-ip": "^3.3.0",
|
|
@@ -71,10 +71,10 @@
|
|
|
71
71
|
"@types/express": "^5.0.6",
|
|
72
72
|
"@types/pg": "^8.18.0",
|
|
73
73
|
"@types/request-ip": "^0.0.41",
|
|
74
|
-
"graphile-test": "^4.
|
|
74
|
+
"graphile-test": "^4.9.0",
|
|
75
75
|
"makage": "^0.3.0",
|
|
76
76
|
"nodemon": "^3.1.14",
|
|
77
|
-
"pgsql-test": "^4.
|
|
77
|
+
"pgsql-test": "^4.9.0",
|
|
78
78
|
"ts-node": "^10.9.2"
|
|
79
79
|
},
|
|
80
80
|
"keywords": [
|
|
@@ -84,5 +84,5 @@
|
|
|
84
84
|
"constructive",
|
|
85
85
|
"graphql"
|
|
86
86
|
],
|
|
87
|
-
"gitHead": "
|
|
87
|
+
"gitHead": "da90c33c7bde52c26611509c438fae42cec48b98"
|
|
88
88
|
}
|
|
@@ -38,7 +38,7 @@ import type { GraphileConfig } from 'graphile-config';
|
|
|
38
38
|
* and adds `+attribute:filterBy` and `+attribute:orderBy` back to ALL columns, regardless of index status.
|
|
39
39
|
*
|
|
40
40
|
* This means:
|
|
41
|
-
* - All columns will appear in the connection filter's
|
|
41
|
+
* - All columns will appear in the connection filter's `where` argument
|
|
42
42
|
* - All columns will appear in the connection's orderBy enum
|
|
43
43
|
* - Developers can filter and sort by any column
|
|
44
44
|
* - It's the developer's/DBA's responsibility to add indexes for frequently filtered/sorted columns
|
|
@@ -40,7 +40,7 @@ exports.EnableAllFilterColumnsPreset = exports.EnableAllFilterColumnsPlugin = vo
|
|
|
40
40
|
* and adds `+attribute:filterBy` and `+attribute:orderBy` back to ALL columns, regardless of index status.
|
|
41
41
|
*
|
|
42
42
|
* This means:
|
|
43
|
-
* - All columns will appear in the connection filter's
|
|
43
|
+
* - All columns will appear in the connection filter's `where` argument
|
|
44
44
|
* - All columns will appear in the connection's orderBy enum
|
|
45
45
|
* - Developers can filter and sort by any column
|
|
46
46
|
* - It's the developer's/DBA's responsibility to add indexes for frequently filtered/sorted columns
|
|
@@ -31,8 +31,8 @@ import type { GraphileConfig } from 'graphile-config';
|
|
|
31
31
|
*
|
|
32
32
|
* RELATION FILTERS:
|
|
33
33
|
* - Enabled via connectionFilterRelations: true
|
|
34
|
-
* - Forward: filter child by parent (e.g. allOrders(
|
|
35
|
-
* - Backward: filter parent by children (e.g. allClients(
|
|
34
|
+
* - Forward: filter child by parent (e.g. allOrders(where: { clientByClientId: { name: { startsWith: "Acme" } } }))
|
|
35
|
+
* - Backward: filter parent by children (e.g. allClients(where: { ordersByClientId: { some: { total: { greaterThan: 1000 } } } }))
|
|
36
36
|
*
|
|
37
37
|
* USAGE:
|
|
38
38
|
* ```typescript
|
|
@@ -44,8 +44,8 @@ const bucket_provisioner_resolver_1 = require("../bucket-provisioner-resolver");
|
|
|
44
44
|
*
|
|
45
45
|
* RELATION FILTERS:
|
|
46
46
|
* - Enabled via connectionFilterRelations: true
|
|
47
|
-
* - Forward: filter child by parent (e.g. allOrders(
|
|
48
|
-
* - Backward: filter parent by children (e.g. allClients(
|
|
47
|
+
* - Forward: filter child by parent (e.g. allOrders(where: { clientByClientId: { name: { startsWith: "Acme" } } }))
|
|
48
|
+
* - Backward: filter parent by children (e.g. allClients(where: { ordersByClientId: { some: { total: { greaterThan: 1000 } } } }))
|
|
49
49
|
*
|
|
50
50
|
* USAGE:
|
|
51
51
|
* ```typescript
|
|
@@ -95,9 +95,11 @@ exports.ConstructivePreset = {
|
|
|
95
95
|
],
|
|
96
96
|
/**
|
|
97
97
|
* Disable PostGraphile core's condition argument entirely.
|
|
98
|
-
* All filtering now lives under the `
|
|
99
|
-
* graphile-connection-filter plugin
|
|
100
|
-
*
|
|
98
|
+
* All filtering now lives under the `where` argument via our v5-native
|
|
99
|
+
* graphile-connection-filter plugin (which renames the default `filter`
|
|
100
|
+
* argument to `where` via `connectionFilterArgumentName: 'where'`).
|
|
101
|
+
* Search, BM25, pgvector, and PostGIS filter fields all hook into
|
|
102
|
+
* `isPgConnectionFilter` instead of `isPgCondition`.
|
|
101
103
|
*/
|
|
102
104
|
disablePlugins: [
|
|
103
105
|
'PgConditionArgumentPlugin',
|
|
@@ -106,7 +108,7 @@ exports.ConstructivePreset = {
|
|
|
106
108
|
/**
|
|
107
109
|
* Connection Filter Plugin Configuration
|
|
108
110
|
*
|
|
109
|
-
* These options control what fields appear in the `
|
|
111
|
+
* These options control what fields appear in the `where` argument on connections.
|
|
110
112
|
* Our v5-native graphile-connection-filter plugin controls relation filters via the
|
|
111
113
|
* `connectionFilterRelations` option passed to ConnectionFilterPreset().
|
|
112
114
|
*
|
|
@@ -132,13 +134,13 @@ exports.ConstructivePreset = {
|
|
|
132
134
|
/**
|
|
133
135
|
* connectionFilterLogicalOperators: true (default)
|
|
134
136
|
* Keeps `and`, `or`, `not` operators for combining filter conditions.
|
|
135
|
-
* Example:
|
|
137
|
+
* Example: where: { or: [{ name: { eq: "foo" } }, { name: { eq: "bar" } }] }
|
|
136
138
|
*/
|
|
137
139
|
connectionFilterLogicalOperators: true,
|
|
138
140
|
/**
|
|
139
141
|
* connectionFilterArrays: true (default)
|
|
140
142
|
* Allows filtering on PostgreSQL array columns.
|
|
141
|
-
* Example:
|
|
143
|
+
* Example: where: { tags: { contains: ["important"] } }
|
|
142
144
|
*/
|
|
143
145
|
connectionFilterArrays: true,
|
|
144
146
|
/**
|