@ttoss/graphql-api-server 0.5.3 → 0.5.5

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/dist/esm/index.js CHANGED
@@ -20,7 +20,11 @@ var createServer = ({
20
20
  schema: buildSchema(buildSchemaInput),
21
21
  graphiql,
22
22
  landingPage: false,
23
- logging: false
23
+ logging: false,
24
+ /**
25
+ * Disable CORS, as it's handled by Koa middleware
26
+ */
27
+ cors: false
24
28
  });
25
29
  const jwtVerifier = (() => {
26
30
  if (authenticationType === "AMAZON_COGNITO_USER_POOLS") {
package/dist/index.js CHANGED
@@ -61,7 +61,11 @@ var createServer = ({
61
61
  schema: (0, import_graphql_api.buildSchema)(buildSchemaInput),
62
62
  graphiql,
63
63
  landingPage: false,
64
- logging: false
64
+ logging: false,
65
+ /**
66
+ * Disable CORS, as it's handled by Koa middleware
67
+ */
68
+ cors: false
65
69
  });
66
70
  const jwtVerifier = (() => {
67
71
  if (authenticationType === "AMAZON_COGNITO_USER_POOLS") {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ttoss/graphql-api-server",
3
- "version": "0.5.3",
3
+ "version": "0.5.5",
4
4
  "description": "GraphQL API Server",
5
5
  "author": "ttoss",
6
6
  "contributors": [
@@ -11,24 +11,28 @@
11
11
  "url": "https://github.com/ttoss/ttoss.git",
12
12
  "directory": "packages/graphql-api-server"
13
13
  },
14
- "main": "dist/index.js",
15
- "module": "dist/esm/index.js",
14
+ "exports": {
15
+ ".": {
16
+ "import": "./dist/esm/index.js",
17
+ "require": "./dist/index.js",
18
+ "types": "./dist/index.d.ts"
19
+ }
20
+ },
16
21
  "files": [
17
22
  "dist",
18
23
  "src"
19
24
  ],
20
25
  "sideEffects": false,
21
- "typings": "dist/index.d.ts",
22
26
  "dependencies": {
23
27
  "@koa/cors": "^5.0.0",
24
28
  "@koa/router": "^12.0.1",
25
29
  "graphql-yoga": "^5.1.1",
26
30
  "koa": "^2.15.0",
27
- "@ttoss/auth-core": "^0.0.2"
31
+ "@ttoss/auth-core": "^0.0.3"
28
32
  },
29
33
  "peerDependencies": {
30
34
  "graphql": "^16.6.0",
31
- "@ttoss/graphql-api": "^0.5.0"
35
+ "@ttoss/graphql-api": "^0.5.1"
32
36
  },
33
37
  "devDependencies": {
34
38
  "@types/koa": "^2.14.0",
@@ -38,9 +42,9 @@
38
42
  "graphql": "^16.8.1",
39
43
  "jest": "^29.7.0",
40
44
  "supertest": "^6.3.4",
41
- "tsup": "^8.0.1",
42
- "@ttoss/config": "^1.31.4",
43
- "@ttoss/graphql-api": "^0.5.0"
45
+ "tsup": "^8.0.2",
46
+ "@ttoss/config": "^1.31.5",
47
+ "@ttoss/graphql-api": "^0.5.1"
44
48
  },
45
49
  "keywords": [
46
50
  "api",
package/src/index.ts CHANGED
@@ -39,6 +39,10 @@ export const createServer = ({
39
39
  graphiql,
40
40
  landingPage: false,
41
41
  logging: false,
42
+ /**
43
+ * Disable CORS, as it's handled by Koa middleware
44
+ */
45
+ cors: false,
42
46
  });
43
47
 
44
48
  const jwtVerifier = (() => {