@wpnuxt/core 1.0.0-edge.20 → 1.0.0-edge.22

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/module.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wpnuxt/core",
3
- "version": "1.0.0-edge.20",
3
+ "version": "1.0.0-edge.22",
4
4
  "configKey": "wpNuxt",
5
5
  "nuxt": ">=3.1.0",
6
6
  "builder": {
package/dist/module.mjs CHANGED
@@ -7,7 +7,7 @@ import { upperFirst } from 'scule';
7
7
  import { parse } from 'graphql';
8
8
 
9
9
  const name = "@wpnuxt/core";
10
- const version = "1.0.0-edge.20";
10
+ const version = "1.0.0-edge.22";
11
11
 
12
12
  const loggerRef = ref();
13
13
  const initLogger = (logLevel) => {
@@ -302,28 +302,6 @@ const module = defineNuxtModule({
302
302
  includeComposables: true,
303
303
  devtools: true
304
304
  });
305
- const resolvedPath = resolveRuntimeModule("./app/graphqlMiddleware.serverOptions");
306
- const template = addTemplate({
307
- filename: "graphqlMiddleware.serverOptions.ts",
308
- write: true,
309
- getContents: () => `
310
- import type { GraphqlMiddlewareServerOptions } from '#graphql-middleware/types'
311
- import serverOptions from '${resolvedPath}'
312
- import type { GraphqlServerResponse } from '#graphql-middleware/types'
313
- import type { GraphqlMiddlewareResponseUnion } from '#build/nuxt-graphql-middleware'
314
-
315
- type GraphqlResponseAdditions =
316
- typeof serverOptions extends GraphqlMiddlewareServerOptions<infer R> ? R : {}
317
-
318
- export type GraphqlResponse<T> = GraphqlServerResponse<T> & GraphqlResponseAdditions
319
-
320
- export type GraphqlResponseTyped = GraphqlResponse<GraphqlMiddlewareResponseUnion>
321
-
322
- export { serverOptions }
323
- `
324
- });
325
- nuxt.options.nitro.externals.inline.push(template.dst);
326
- nuxt.options.alias["#graphql-middleware-server-options-build"] = template.dst;
327
305
  logger.trace("Start generating composables");
328
306
  const ctx = await {
329
307
  fns: [],
@@ -2,5 +2,5 @@ import type { FetchError } from 'ofetch';
2
2
  import type { OperationTypeNode } from 'graphql';
3
3
  export declare const useWPContent: <T>(operation: OperationTypeNode, queryName: string, nodes: string[], fixImagePaths: boolean, params?: T) => Promise<{
4
4
  data: unknown;
5
- error: import("vue").Ref<FetchError<any> | null>;
5
+ error: import("vue").Ref<FetchError<any> | null, FetchError<any> | null>;
6
6
  }>;
@@ -1,3 +1,5 @@
1
+ import { defineCachedEventHandler } from "#internal/nitro";
2
+ import { useRuntimeConfig } from "#imports";
1
3
  export default defineCachedEventHandler(async (event) => {
2
4
  const config = useRuntimeConfig(event);
3
5
  return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wpnuxt/core",
3
- "version": "1.0.0-edge.20",
3
+ "version": "1.0.0-edge.22",
4
4
  "description": "WPNuxt",
5
5
  "repository": {
6
6
  "type": "git",
@@ -52,13 +52,13 @@
52
52
  "start": "pnpm run wp-env:create && pnpm run dev"
53
53
  },
54
54
  "dependencies": {
55
- "@nuxt/kit": "3.13.0",
55
+ "@nuxt/kit": "3.13.1",
56
56
  "@vueuse/nuxt": "^11.0.3",
57
57
  "defu": "^6.1.4",
58
58
  "graphql": "^16.9.0",
59
59
  "nuxt-graphql-middleware": "4.1.1",
60
60
  "ohash": "^1.1.3",
61
- "unstorage": "^1.10.2",
61
+ "unstorage": "^1.11.1",
62
62
  "vue-sanitize-directive": "^0.2.1"
63
63
  },
64
64
  "devDependencies": {
@@ -66,29 +66,29 @@
66
66
  "@graphql-codegen/client-preset": "^4.3.3",
67
67
  "@graphql-codegen/typescript-operations": "^4.2.3",
68
68
  "@nuxt/devtools": "^1.4.1",
69
- "@nuxt/eslint-config": "^0.5.4",
69
+ "@nuxt/eslint-config": "^0.5.5",
70
70
  "@nuxt/module-builder": "^0.8.3",
71
- "@nuxt/schema": "3.13.0",
71
+ "@nuxt/schema": "3.13.1",
72
72
  "@nuxt/test-utils": "^3.14.1",
73
73
  "@rollup/rollup-linux-arm64-gnu": "^4.21.2",
74
74
  "@rollup/rollup-linux-arm64-musl": "^4.21.2",
75
- "@types/node": "22.5.1",
75
+ "@types/node": "22.5.3",
76
76
  "@vitest/coverage-v8": "^2.0.5",
77
77
  "@vue/test-utils": "^2.4.6",
78
78
  "@wordpress/env": "^10.6.0",
79
79
  "changelogen": "^0.5.5",
80
80
  "markdownlint-cli": "^0.41.0",
81
- "nuxt": "^3.13.0",
81
+ "nuxt": "^3.13.1",
82
82
  "nuxt-content-twoslash": "^0.1.1",
83
83
  "release-it": "^17.6.0",
84
- "shiki": "^1.15.0",
85
- "twoslash": "^0.2.9",
84
+ "shiki": "^1.16.1",
85
+ "twoslash": "^0.2.10",
86
86
  "typescript": "^5.5.4",
87
87
  "untyped": "1.4.2",
88
- "vite": "^5.4.2",
88
+ "vite": "^5.4.3",
89
89
  "vitest": "^2.0.5",
90
90
  "vue-docgen-web-types": "^0.1.8",
91
- "vue-tsc": "2.1.2"
91
+ "vue-tsc": "2.1.4"
92
92
  },
93
93
  "peerDependencies": {
94
94
  "consola": "^3.2.3",
@@ -1,2 +0,0 @@
1
- declare const _default: import("nuxt-graphql-middleware").GraphqlMiddlewareServerOptions<object>;
2
- export default _default;
@@ -1,11 +0,0 @@
1
- import { defineGraphqlServerOptions } from "nuxt-graphql-middleware/dist/runtime/serverOptions";
2
- import { getHeader } from "h3";
3
- export default defineGraphqlServerOptions({
4
- serverFetchOptions(event) {
5
- return {
6
- headers: {
7
- Authorization: getHeader(event, "Authorization")
8
- }
9
- };
10
- }
11
- });