Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] React Router 7 integration #394

Draft
wants to merge 27 commits into
base: pr/multipart-streaming
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
1814410
initialize basic react-router project
phryneas Nov 25, 2024
22c1894
clean up and `yarn react-router reveal`
phryneas Nov 25, 2024
294d6e8
add raw experiment
phryneas Nov 25, 2024
f909ae4
move eslint config into shared position
phryneas Dec 16, 2024
9252735
Fix bundling configuration so parts of the `graphql` package don't en…
phryneas Nov 13, 2024
d4dd572
Release version 0.11.6@latest to npm
phryneas Nov 13, 2024
312629f
Update peer deps for React 19 compatibility (#399)
nphmuller Dec 6, 2024
cfb9d68
update devDependencies to React 19, adjust tests and examples (#400)
phryneas Dec 6, 2024
145f210
Release version 0.11.7@latest to npm
phryneas Dec 6, 2024
bf662df
add example
phryneas Dec 16, 2024
30a154b
update react-router
phryneas Dec 16, 2024
13a3c39
working
phryneas Dec 16, 2024
8318d85
patch PR in
phryneas Dec 16, 2024
6f67975
last adjustments
phryneas Dec 16, 2024
75a49c9
Merge branch 'pr/multipart-streaming' into pr/react-router-7
phryneas Dec 18, 2024
2b91422
clean up template fluff
phryneas Dec 18, 2024
7414a6b
move `IncrementalSchemaLink` and others to `shared`
phryneas Dec 18, 2024
27c5178
use `@defer` in the example
phryneas Dec 18, 2024
7672128
update turbo-stream patch
phryneas Dec 19, 2024
4040b28
update example to React 19
phryneas Dec 19, 2024
9c9945e
adjust `prepublishOnly`
phryneas Dec 20, 2024
849f09b
add to pkg-pr-new-publish
phryneas Dec 20, 2024
f62cb1b
add empty unit test
phryneas Dec 20, 2024
90b50b3
increase delay
phryneas Dec 20, 2024
e2d90b3
streamline integration test build
phryneas Dec 20, 2024
c98500e
needs more time in CI
phryneas Dec 20, 2024
93e20db
exclude shared
phryneas Dec 20, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/pkg-pr-new-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ jobs:
run: yarn build:libs

- name: Build and publish to pkg.pr.new
run: yarn dlx pkg-pr-new publish --no-template packages/client-react-streaming packages/experimental-nextjs-app-support
run: yarn dlx pkg-pr-new publish --no-template packages/client-react-streaming packages/experimental-nextjs-app-support packages/react-router
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ jobs:
YARN_ENABLE_IMMUTABLE_INSTALLS: "false"

- name: Set target version of Apollo Client (Integration Test)
run: yarn workspaces foreach --all --include "@integration-test/*" add @apollo/client@${{ matrix.version }}
run: yarn workspaces foreach --all --include "@integration-test/*" --exclude @integration-test/shared add @apollo/client@${{ matrix.version }}

- name: Get installed Playwright version
id: playwright-version
Expand Down
94 changes: 94 additions & 0 deletions .yarn/patches/react-router-npm-7.0.2-b96f2bd13c.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
diff --git a/dist/development/lib/types/route-module.d.mts b/dist/development/lib/types/route-module.d.mts
index c4553062633a6a1352378bfedb2c9dc7eaef94fb..762fd83a1ad06f940ba39c6552bd61cc5c4d1cf1 100644
--- a/dist/development/lib/types/route-module.d.mts
+++ b/dist/development/lib/types/route-module.d.mts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.mjs';
import { A as AppLoadContext } from '../../data-CQbyyGzl.mjs';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
diff --git a/dist/development/lib/types/route-module.d.ts b/dist/development/lib/types/route-module.d.ts
index a7b3449b84f7be4e7da9ce82ba6ac3ae3e30d64f..776fdbc13033eb82ce4de2b9026476e87e65c7f7 100644
--- a/dist/development/lib/types/route-module.d.ts
+++ b/dist/development/lib/types/route-module.d.ts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.js';
import { A as AppLoadContext } from '../../data-CQbyyGzl.js';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
diff --git a/dist/development/route-data-DuV3tXo2.d.mts b/dist/development/route-data-DuV3tXo2.d.mts
index 53dbfb38b8c2cd09bb944aeb17dd3951f2a157ad..d33adfc7147222f4e283487df804faeb95f2a4c8 100644
--- a/dist/development/route-data-DuV3tXo2.d.mts
+++ b/dist/development/route-data-DuV3tXo2.d.mts
@@ -1531,8 +1531,10 @@ type Func = (...args: any[]) => unknown;
type Pretty<T> = {
[K in keyof T]: T[K];
} & {};
-
-type Serialize<T> = T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
+type Serialize<T> = T extends SerializesTo<infer To> ? To : T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
[K in keyof T]: Serialize<T[K]>;
} : undefined;
type VoidToUndefined<T> = Equal<T, void> extends true ? undefined : T;
diff --git a/dist/development/route-data-DuV3tXo2.d.ts b/dist/development/route-data-DuV3tXo2.d.ts
index 53dbfb38b8c2cd09bb944aeb17dd3951f2a157ad..d33adfc7147222f4e283487df804faeb95f2a4c8 100644
--- a/dist/development/route-data-DuV3tXo2.d.ts
+++ b/dist/development/route-data-DuV3tXo2.d.ts
@@ -1531,8 +1531,10 @@ type Func = (...args: any[]) => unknown;
type Pretty<T> = {
[K in keyof T]: T[K];
} & {};
-
-type Serialize<T> = T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
+type Serialize<T> = T extends SerializesTo<infer To> ? To : T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
[K in keyof T]: Serialize<T[K]>;
} : undefined;
type VoidToUndefined<T> = Equal<T, void> extends true ? undefined : T;
diff --git a/dist/production/lib/types/route-module.d.mts b/dist/production/lib/types/route-module.d.mts
index c4553062633a6a1352378bfedb2c9dc7eaef94fb..762fd83a1ad06f940ba39c6552bd61cc5c4d1cf1 100644
--- a/dist/production/lib/types/route-module.d.mts
+++ b/dist/production/lib/types/route-module.d.mts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.mjs';
import { A as AppLoadContext } from '../../data-CQbyyGzl.mjs';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
diff --git a/dist/production/lib/types/route-module.d.ts b/dist/production/lib/types/route-module.d.ts
index a7b3449b84f7be4e7da9ce82ba6ac3ae3e30d64f..776fdbc13033eb82ce4de2b9026476e87e65c7f7 100644
--- a/dist/production/lib/types/route-module.d.ts
+++ b/dist/production/lib/types/route-module.d.ts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.js';
import { A as AppLoadContext } from '../../data-CQbyyGzl.js';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
diff --git a/dist/development/lib/types/route-module.d.mts b/dist/development/lib/types/route-module.d.mts
index c4553062633a6a1352378bfedb2c9dc7eaef94fb..762fd83a1ad06f940ba39c6552bd61cc5c4d1cf1 100644
--- a/dist/development/lib/types/route-module.d.mts
+++ b/dist/development/lib/types/route-module.d.mts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.mjs';
import { A as AppLoadContext } from '../../data-CQbyyGzl.mjs';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
diff --git a/dist/development/lib/types/route-module.d.ts b/dist/development/lib/types/route-module.d.ts
index a7b3449b84f7be4e7da9ce82ba6ac3ae3e30d64f..776fdbc13033eb82ce4de2b9026476e87e65c7f7 100644
--- a/dist/development/lib/types/route-module.d.ts
+++ b/dist/development/lib/types/route-module.d.ts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.js';
import { A as AppLoadContext } from '../../data-CQbyyGzl.js';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
diff --git a/dist/development/route-data-DuV3tXo2.d.mts b/dist/development/route-data-DuV3tXo2.d.mts
index 53dbfb38b8c2cd09bb944aeb17dd3951f2a157ad..d33adfc7147222f4e283487df804faeb95f2a4c8 100644
--- a/dist/development/route-data-DuV3tXo2.d.mts
+++ b/dist/development/route-data-DuV3tXo2.d.mts
@@ -1531,8 +1531,10 @@ type Func = (...args: any[]) => unknown;
type Pretty<T> = {
[K in keyof T]: T[K];
} & {};
-
-type Serialize<T> = T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
+type Serialize<T> = T extends SerializesTo<infer To> ? To : T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
[K in keyof T]: Serialize<T[K]>;
} : undefined;
type VoidToUndefined<T> = Equal<T, void> extends true ? undefined : T;
diff --git a/dist/development/route-data-DuV3tXo2.d.ts b/dist/development/route-data-DuV3tXo2.d.ts
index 53dbfb38b8c2cd09bb944aeb17dd3951f2a157ad..d33adfc7147222f4e283487df804faeb95f2a4c8 100644
--- a/dist/development/route-data-DuV3tXo2.d.ts
+++ b/dist/development/route-data-DuV3tXo2.d.ts
@@ -1531,8 +1531,10 @@ type Func = (...args: any[]) => unknown;
type Pretty<T> = {
[K in keyof T]: T[K];
} & {};
-
-type Serialize<T> = T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
+type Serialize<T> = T extends SerializesTo<infer To> ? To : T extends Serializable ? T : T extends (...args: any[]) => unknown ? undefined : T extends Promise<infer U> ? Promise<Serialize<U>> : T extends Map<infer K, infer V> ? Map<Serialize<K>, Serialize<V>> : T extends Set<infer U> ? Set<Serialize<U>> : T extends [] ? [] : T extends readonly [infer F, ...infer R] ? [Serialize<F>, ...Serialize<R>] : T extends Array<infer U> ? Array<Serialize<U>> : T extends readonly unknown[] ? readonly Serialize<T[number]>[] : T extends Record<any, any> ? {
[K in keyof T]: Serialize<T[K]>;
} : undefined;
type VoidToUndefined<T> = Equal<T, void> extends true ? undefined : T;
diff --git a/dist/production/lib/types/route-module.d.mts b/dist/production/lib/types/route-module.d.mts
index c4553062633a6a1352378bfedb2c9dc7eaef94fb..762fd83a1ad06f940ba39c6552bd61cc5c4d1cf1 100644
--- a/dist/production/lib/types/route-module.d.mts
+++ b/dist/production/lib/types/route-module.d.mts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.mjs';
import { A as AppLoadContext } from '../../data-CQbyyGzl.mjs';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
diff --git a/dist/production/lib/types/route-module.d.ts b/dist/production/lib/types/route-module.d.ts
index a7b3449b84f7be4e7da9ce82ba6ac3ae3e30d64f..776fdbc13033eb82ce4de2b9026476e87e65c7f7 100644
--- a/dist/production/lib/types/route-module.d.ts
+++ b/dist/production/lib/types/route-module.d.ts
@@ -1,7 +1,9 @@
import { av as LinkDescriptor, as as MetaDescriptor, aJ as ServerDataFrom, aK as ClientDataFrom, aL as Func, aM as Equal, aN as Pretty } from '../../route-data-DuV3tXo2.js';
import { A as AppLoadContext } from '../../data-CQbyyGzl.js';
import 'react';
-
+export type SerializesTo<T> = {
+ $__RR_SerializesTo?: [T];
+ };
type IsDefined<T> = Equal<T, undefined> extends true ? false : true;
type RouteModule = {
meta?: Func;
1 change: 1 addition & 0 deletions integration-test/nextjs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"@apollo/server": "^4.11.2",
"@as-integrations/next": "^3.2.0",
"@graphql-tools/schema": "^10.0.0",
"@integration-test/shared": "workspace:^",
"@types/node": "20.3.1",
"@types/react": "^19.0.0",
"@types/react-dom": "^19.0.0",
Expand Down
4 changes: 2 additions & 2 deletions integration-test/nextjs/src/app/cc/ApolloWrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ import {
import { loadErrorMessages, loadDevMessages } from "@apollo/client/dev";
import { setVerbosity } from "ts-invariant";
import { delayLink } from "@/shared/delayLink";
import { schema } from "../graphql/schema";
import { schema } from "@integration-test/shared/schema";

import { useSSROnlySecret } from "ssr-only-secrets";
import { errorLink } from "../../shared/errorLink";
import { IncrementalSchemaLink } from "../graphql/IncrementalSchemaLink";
import { IncrementalSchemaLink } from "@integration-test/shared/IncrementalSchemaLink";

setVerbosity("debug");
loadDevMessages();
Expand Down
2 changes: 1 addition & 1 deletion integration-test/nextjs/src/app/graphql/route.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { startServerAndCreateNextHandler } from "@as-integrations/next";
import { ApolloServer } from "@apollo/server";
import { schema } from "./schema";
import { schema } from "@integration-test/shared/schema";

const server = new ApolloServer({
schema,
Expand Down
4 changes: 2 additions & 2 deletions integration-test/nextjs/src/app/rsc/client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import { setVerbosity } from "ts-invariant";
import { delayLink } from "@/shared/delayLink";
import { errorLink } from "@/shared/errorLink";

import { schema } from "../graphql/schema";
import { IncrementalSchemaLink } from "../graphql/IncrementalSchemaLink";
import { schema } from "@integration-test/shared/schema";
import { IncrementalSchemaLink } from "@integration-test/shared/IncrementalSchemaLink";

setVerbosity("debug");
loadDevMessages();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {
useQueryRefHandlers,
useReadQuery,
} from "@apollo/client";
import { DeferredDynamicProductResult } from "../shared";
import { DeferredDynamicProductResult } from "@integration-test/shared/queries";
import { TransportedQueryRef } from "@apollo/experimental-nextjs-app-support";
import { useTransition } from "react";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ApolloWrapper } from "@/app/cc/ApolloWrapper";
import { ClientChild } from "./ClientChild";
import { DEFERRED_QUERY } from "../shared";
import { DEFERRED_QUERY } from "@integration-test/shared/queries";

export const dynamic = "force-dynamic";
import { PreloadQuery } from "../../../client";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"use client";

import { QueryRef, useQueryRefHandlers } from "@apollo/client";
import { DynamicProductResult } from "../shared";
import { DynamicProductResult } from "@integration-test/shared/queries";
import { useEffect, useState } from "react";
import {
InternalQueryReference,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { QUERY } from "../shared";
import { QUERY } from "@integration-test/shared/queries";
import { Suspense } from "react";
import { PreloadQuery } from "@/app/rsc/client";
import { RefTestChild } from "./RefTestChild";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"use client";

import { useQueryRefHandlers, useReadQuery } from "@apollo/client";
import { DynamicProductResult } from "../shared";
import { DynamicProductResult } from "@integration-test/shared/queries";
import { TransportedQueryRef } from "@apollo/experimental-nextjs-app-support";

export function ClientChild({
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ApolloWrapper } from "@/app/cc/ApolloWrapper";
import { ClientChild } from "./ClientChild";
import { QUERY } from "../shared";
import { QUERY } from "@integration-test/shared/queries";

export const dynamic = "force-dynamic";
import { PreloadQuery } from "../../../client";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"use client";

import { useSuspenseQuery } from "@apollo/client";
import { QUERY } from "../shared";
import { QUERY } from "@integration-test/shared/queries";

export function ClientChild() {
const { data } = useSuspenseQuery(QUERY);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { ApolloWrapper } from "@/app/cc/ApolloWrapper";
import { ClientChild } from "./ClientChild";
import { QUERY } from "../shared";
import { QUERY } from "@integration-test/shared/queries";

export const dynamic = "force-dynamic";
import { PreloadQuery } from "../../../client";
Expand Down
2 changes: 1 addition & 1 deletion integration-test/nextjs/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@
"@/*": ["./src/*"]
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts", "../shared/*.ts"],
"exclude": ["node_modules"]
}
6 changes: 4 additions & 2 deletions integration-test/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@
"resolutions": {
"@apollo/client-react-streaming": "exec:./shared/build-client-react-streaming.cjs",
"@apollo/experimental-nextjs-app-support": "exec:./shared/build-experimental-nextjs-app-support.cjs",
"graphql": "17.0.0-alpha.2"
"@apollo/client-integration-react-router": "exec:./shared/build-client-integration-react-router.cjs",
"graphql": "17.0.0-alpha.2",
"turbo-stream": "npm:@phryneas/[email protected]"
},
"workspaces": [
"*"
],
"scripts": {
"build:libs": "find . -regextype posix-extended -regex '.*/node_modules/@apollo/(client-react-streaming|experimental-nextjs-app-support)' -printf 'rm -r %p\n' -exec rm -r {} +; glob \"../.yarn/cache/@apollo-*exec*\" \"$HOME/.yarn/berry/cache/@apollo-*exec*\" --cmd='rm -v' ; yarn"
"build:libs": "find . -regextype posix-extended -regex '.*/node_modules/@apollo/(client-react-streaming|experimental-nextjs-app-support|client-integration-react-router)' -printf 'rm -r %p\n' -exec rm -r {} +; glob \"../.yarn/cache/@apollo-*exec*\" \"$HOME/.yarn/berry/cache/@apollo-*exec*\" --cmd='rm -v' ; yarn"
},
"devDependencies": {
"glob": "^10.3.10"
Expand Down
7 changes: 7 additions & 0 deletions integration-test/react-router/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
.env
!.env.example
.DS_Store
.react-router
build
node_modules
*.tsbuildinfo
Loading
Loading