payload 1.6.2 → 1.6.3
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function generateGraphQLSchema(): void
|
|
1
|
+
export declare function generateGraphQLSchema(): Promise<void>;
|
|
@@ -10,10 +10,10 @@ const graphql_1 = require("graphql");
|
|
|
10
10
|
const logger_1 = __importDefault(require("../utilities/logger"));
|
|
11
11
|
const load_1 = __importDefault(require("../config/load"));
|
|
12
12
|
const __1 = __importDefault(require(".."));
|
|
13
|
-
function generateGraphQLSchema() {
|
|
13
|
+
async function generateGraphQLSchema() {
|
|
14
14
|
const logger = (0, logger_1.default)();
|
|
15
15
|
const config = (0, load_1.default)();
|
|
16
|
-
__1.default.init({
|
|
16
|
+
await __1.default.init({
|
|
17
17
|
secret: '--unused--',
|
|
18
18
|
mongoURL: false,
|
|
19
19
|
local: true,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generateGraphQLSchema.js","sourceRoot":"","sources":["../../src/bin/generateGraphQLSchema.ts"],"names":[],"mappings":";;;;;;AAAA,sCAAsC;AACtC,4CAAoB;AACpB,qCAAsC;AACtC,iEAAyC;AACzC,0DAAwC;AACxC,2CAAyB;
|
|
1
|
+
{"version":3,"file":"generateGraphQLSchema.js","sourceRoot":"","sources":["../../src/bin/generateGraphQLSchema.ts"],"names":[],"mappings":";;;;;;AAAA,sCAAsC;AACtC,4CAAoB;AACpB,qCAAsC;AACtC,iEAAyC;AACzC,0DAAwC;AACxC,2CAAyB;AAElB,KAAK,UAAU,qBAAqB;IACzC,MAAM,MAAM,GAAG,IAAA,gBAAM,GAAE,CAAC;IACxB,MAAM,MAAM,GAAG,IAAA,cAAU,GAAE,CAAC;IAE5B,MAAM,WAAO,CAAC,IAAI,CAAC;QACjB,MAAM,EAAE,YAAY;QACpB,QAAQ,EAAE,KAAK;QACf,KAAK,EAAE,IAAI;KACZ,CAAC,CAAC;IAEH,MAAM,CAAC,IAAI,CAAC,6BAA6B,CAAC,CAAC;IAC3C,YAAE,CAAC,aAAa,CAAC,MAAM,CAAC,OAAO,CAAC,gBAAgB,EAAE,IAAA,qBAAW,EAAC,WAAO,CAAC,MAAM,CAAC,CAAC,CAAC;IAC/E,MAAM,CAAC,IAAI,CAAC,sBAAsB,MAAM,CAAC,OAAO,CAAC,gBAAgB,EAAE,CAAC,CAAC;AACvE,CAAC;AAbD,sDAaC;AAED,qDAAqD;AACrD,IAAI,MAAM,CAAC,EAAE,KAAK,OAAO,CAAC,IAAI,CAAC,EAAE,EAAE;IACjC,qBAAqB,EAAE,CAAC;CACzB"}
|
|
@@ -45,7 +45,7 @@ To add an NPM script to generate your types and show Payload where to find your
|
|
|
45
45
|
```json
|
|
46
46
|
{
|
|
47
47
|
"scripts": {
|
|
48
|
-
"generate:graphQLSchema": "PAYLOAD_CONFIG_PATH=src/payload.config.ts payload generate:graphQLSchema",
|
|
48
|
+
"generate:graphQLSchema": "cross-env PAYLOAD_CONFIG_PATH=src/payload.config.ts payload generate:graphQLSchema",
|
|
49
49
|
},
|
|
50
50
|
}
|
|
51
51
|
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "payload",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.3",
|
|
4
4
|
"description": "Node, React and MongoDB Headless CMS and Application Framework",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"engines": {
|
|
@@ -38,6 +38,7 @@
|
|
|
38
38
|
"build:watch": "nodemon --watch 'src/**' --ext 'ts,tsx' --exec \"yarn build:tsc\"",
|
|
39
39
|
"dev": "nodemon",
|
|
40
40
|
"dev:generate-types": "ts-node -T ./test/generateTypes.ts",
|
|
41
|
+
"dev:generate-graphql-schema": "cross-env PAYLOAD_CONFIG_PATH=test/graphql-schema-gen/config.ts ts-node -T ./src/bin/generateGraphQLSchema.ts",
|
|
41
42
|
"pretest": "yarn build",
|
|
42
43
|
"test": "yarn test:int && yarn test:components && yarn test:e2e",
|
|
43
44
|
"test:int": "cross-env DISABLE_LOGGING=true jest --forceExit --detectOpenHandles",
|