graphile-build-pg
Advanced tools
Comparing version 4.0.0-alpha.4 to 4.0.0-alpha.5
@@ -6,3 +6,3 @@ "use strict"; | ||
}); | ||
exports.constantCase = exports.camelCase = exports.upperFirst = exports.PgMutationPayloadEdgePlugin = exports.PgMutationProceduresPlugin = exports.PgMutationUpdateDeletePlugin = exports.PgMutationCreatePlugin = exports.PgConnectionTotalCount = exports.PageInfoStartEndCursor = exports.PgScalarFunctionConnectionPlugin = exports.PgNodeAliasPostGraphQL = exports.PgRowNode = exports.PgOrderByPrimaryKeyPlugin = exports.PgOrderAllColumnsPlugin = exports.PgQueryProceduresPlugin = exports.PgComputedColumnsPlugin = exports.PgRowByUniqueConstraint = exports.PgBackwardRelationPlugin = exports.PgForwardRelationPlugin = exports.PgColumnDeprecationPlugin = exports.PgColumnsPlugin = exports.PgAllRows = exports.PgConnectionArgCondition = exports.PgConnectionArgOrderByDefaultValue = exports.PgConnectionArgOrderBy = exports.PgConnectionArgFirstLastBeforeAfter = exports.PgTablesPlugin = exports.PgJWTPlugin = exports.PgTypesPlugin = exports.PgIntrospectionPlugin = exports.PgBasicsPlugin = exports.inflections = exports.defaultPlugins = undefined; | ||
exports.constantCase = exports.camelCase = exports.upperFirst = exports.PgMutationPayloadEdgePlugin = exports.PgMutationProceduresPlugin = exports.PgMutationUpdateDeletePlugin = exports.PgMutationCreatePlugin = exports.PgConnectionTotalCount = exports.PageInfoStartEndCursor = exports.PgScalarFunctionConnectionPlugin = exports.PgNodeAliasPostGraphQL = exports.PgNodeAliasPostGraphile = exports.PgRowNode = exports.PgOrderByPrimaryKeyPlugin = exports.PgOrderAllColumnsPlugin = exports.PgQueryProceduresPlugin = exports.PgComputedColumnsPlugin = exports.PgRowByUniqueConstraint = exports.PgBackwardRelationPlugin = exports.PgForwardRelationPlugin = exports.PgColumnDeprecationPlugin = exports.PgColumnsPlugin = exports.PgAllRows = exports.PgConnectionArgCondition = exports.PgConnectionArgOrderByDefaultValue = exports.PgConnectionArgOrderBy = exports.PgConnectionArgFirstLastBeforeAfter = exports.PgTablesPlugin = exports.PgJWTPlugin = exports.PgTypesPlugin = exports.PgIntrospectionPlugin = exports.PgBasicsPlugin = exports.inflections = exports.defaultPlugins = undefined; | ||
@@ -110,5 +110,5 @@ var _utils = require("./utils"); | ||
var _PgNodeAliasPostGraphQL = require("./plugins/PgNodeAliasPostGraphQL"); | ||
var _PgNodeAliasPostGraphile = require("./plugins/PgNodeAliasPostGraphile"); | ||
var _PgNodeAliasPostGraphQL2 = _interopRequireDefault(_PgNodeAliasPostGraphQL); | ||
var _PgNodeAliasPostGraphile2 = _interopRequireDefault(_PgNodeAliasPostGraphile); | ||
@@ -151,4 +151,4 @@ var _PgScalarFunctionConnectionPlugin = require("./plugins/PgScalarFunctionConnectionPlugin"); | ||
const defaultPlugins = exports.defaultPlugins = [_PgBasicsPlugin2.default, _PgIntrospectionPlugin2.default, _PgTypesPlugin2.default, _PgJWTPlugin2.default, _PgTablesPlugin2.default, _PgConnectionArgFirstLastBeforeAfter2.default, _PgConnectionArgOrderBy2.default, _PgConnectionArgOrderByDefaultValue2.default, _PgConnectionArgCondition2.default, _PgAllRows2.default, _PgColumnsPlugin2.default, _PgColumnDeprecationPlugin2.default, _PgForwardRelationPlugin2.default, _PgBackwardRelationPlugin2.default, _PgRowByUniqueConstraint2.default, _PgComputedColumnsPlugin2.default, _PgQueryProceduresPlugin2.default, _PgOrderAllColumnsPlugin2.default, _PgOrderByPrimaryKeyPlugin2.default, _PgRowNode2.default, _PgNodeAliasPostGraphQL2.default, _PgScalarFunctionConnectionPlugin2.default, // For PostGraphQL compatibility | ||
_PageInfoStartEndCursor2.default, // For PostGraphQL compatibility | ||
const defaultPlugins = exports.defaultPlugins = [_PgBasicsPlugin2.default, _PgIntrospectionPlugin2.default, _PgTypesPlugin2.default, _PgJWTPlugin2.default, _PgTablesPlugin2.default, _PgConnectionArgFirstLastBeforeAfter2.default, _PgConnectionArgOrderBy2.default, _PgConnectionArgOrderByDefaultValue2.default, _PgConnectionArgCondition2.default, _PgAllRows2.default, _PgColumnsPlugin2.default, _PgColumnDeprecationPlugin2.default, _PgForwardRelationPlugin2.default, _PgBackwardRelationPlugin2.default, _PgRowByUniqueConstraint2.default, _PgComputedColumnsPlugin2.default, _PgQueryProceduresPlugin2.default, _PgOrderAllColumnsPlugin2.default, _PgOrderByPrimaryKeyPlugin2.default, _PgRowNode2.default, _PgNodeAliasPostGraphile2.default, _PgScalarFunctionConnectionPlugin2.default, // For PostGraphile compatibility | ||
_PageInfoStartEndCursor2.default, // For PostGraphile compatibility | ||
_PgConnectionTotalCount2.default, | ||
@@ -182,3 +182,4 @@ | ||
exports.PgRowNode = _PgRowNode2.default; | ||
exports.PgNodeAliasPostGraphQL = _PgNodeAliasPostGraphQL2.default; | ||
exports.PgNodeAliasPostGraphile = _PgNodeAliasPostGraphile2.default; | ||
exports.PgNodeAliasPostGraphQL = _PgNodeAliasPostGraphile2.default; | ||
exports.PgScalarFunctionConnectionPlugin = _PgScalarFunctionConnectionPlugin2.default; | ||
@@ -185,0 +186,0 @@ exports.PageInfoStartEndCursor = _PageInfoStartEndCursor2.default; |
@@ -56,3 +56,3 @@ "use strict"; | ||
// Ref: https://github.com/postgraphql/postgraphql/tree/master/src/postgres/introspection/object | ||
// Ref: https://github.com/graphile/postgraphile/tree/master/src/postgres/introspection/object | ||
@@ -189,3 +189,3 @@ function readFile(filename, encoding) { | ||
if (pgClient) { | ||
pgClient.query("unlisten postgraphql_watch").catch(e => { | ||
pgClient.query("unlisten postgraphile_watch").catch(e => { | ||
debug(`Error occurred trying to unlisten watch: ${e}`); | ||
@@ -243,3 +243,3 @@ }); | ||
await pgClient.query("listen postgraphql_watch"); | ||
await pgClient.query("listen postgraphile_watch"); | ||
@@ -254,3 +254,3 @@ const handleChange = async () => { | ||
listener = async notification => { | ||
if (notification.channel !== "postgraphql_watch") { | ||
if (notification.channel !== "postgraphile_watch") { | ||
return; | ||
@@ -257,0 +257,0 @@ } |
@@ -64,5 +64,6 @@ "use strict"; | ||
}, {}); | ||
return (0, _jsonwebtoken.sign)(token, pgJwtSecret, (0, _assign2.default)({}, { | ||
audience: "postgraphql", | ||
issuer: "postgraphql" | ||
return (0, _jsonwebtoken.sign)(token, pgJwtSecret, (0, _assign2.default)({}, token.aud ? null : { | ||
audience: "postgraphile" | ||
}, token.iss ? null : { | ||
issuer: "postgraphile" | ||
}, token.exp ? null : { | ||
@@ -69,0 +70,0 @@ expiresIn: "1 day" |
@@ -577,3 +577,3 @@ "use strict"; | ||
const baseInputType = gqlInputTypeByTypeId[type.domainBaseTypeId]; | ||
// Hack stolen from: https://github.com/postgraphql/postgraphql/blob/ade728ed8f8e3ecdc5fdad7d770c67aa573578eb/src/graphql/schema/type/aliasGqlType.ts#L16 | ||
// Hack stolen from: https://github.com/graphile/postgraphile/blob/ade728ed8f8e3ecdc5fdad7d770c67aa573578eb/src/graphql/schema/type/aliasGqlType.ts#L16 | ||
gqlTypeByTypeId[type.id] = (0, _assign2.default)((0, _create2.default)(baseType), { | ||
@@ -580,0 +580,0 @@ name: inflection.domainType(type.name), |
{ | ||
"name": "graphile-build-pg", | ||
"version": "4.0.0-alpha.4", | ||
"version": "4.0.0-alpha.5", | ||
"description": "Build a GraphQL schema by reflection over a PostgreSQL schema. Easy to customize since it's built with plugins on graphile-build", | ||
@@ -40,3 +40,3 @@ "main": "node8plus/index.js", | ||
"debug": ">=2 <3", | ||
"graphile-build": "4.0.0-alpha.1", | ||
"graphile-build": "4.0.0-alpha.5", | ||
"graphql-iso-date": "^3.2.0", | ||
@@ -43,0 +43,0 @@ "jsonwebtoken": "^8.1.1", |
@@ -1,3 +0,2 @@ | ||
graphile-build-pg | ||
================= | ||
# graphile-build-pg | ||
@@ -13,8 +12,8 @@ `graphile-build-pg` is a collection of plugins for `graphile-build` that allow | ||
An example of an application built on `graphile-build-pg` is [PostGraphQL | ||
v4+](https://github.com/postgraphql/postgraphql) which allows you to run just | ||
An example of an application built on `graphile-build-pg` is [PostGraphile | ||
v4+](https://github.com/graphile/postgraphile) which allows you to run just | ||
one command to instantly get a fully working and secure GraphQL API up and | ||
running based on your PostgreSQL database schema. | ||
**It is recommended that you use PostGraphQL directly unless you really want to | ||
**It is recommended that you use PostGraphile directly unless you really want to | ||
get low level access to this library.** | ||
@@ -38,7 +37,6 @@ | ||
- `defaultInflection` - a sensible default | ||
- `postGraphQLInflection` - as above, but enums get converted to `CONSTANT_CASE` | ||
- `postGraphQLClassicIdsInflection` - as above, but `id` attributes get renamed to `rowId` to prevent conflicts with `id` from the Relay Global Unique Object Specification. | ||
* `defaultInflection` - a sensible default | ||
* `postGraphileInflection` - as above, but enums get converted to `CONSTANT_CASE` | ||
* `postGraphileClassicIdsInflection` - as above, but `id` attributes get renamed to `rowId` to prevent conflicts with `id` from the Relay Global Unique Object Specification. | ||
### Manual usage | ||
@@ -45,0 +43,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
908728
122
4895
67
+ Addedgraphile-build@4.0.0-alpha.5(transitive)
+ Addedgraphql-parse-resolve-info@4.0.0-alpha.5(transitive)
- Removedgraphile-build@4.0.0-alpha.1(transitive)
- Removedgraphql-parse-resolve-info@4.0.0-alpha.1(transitive)
Updatedgraphile-build@4.0.0-alpha.5