-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
manually update various tooling-related dependencies #12286
Conversation
|
✅ Docs preview has no changesThe preview was not built because there were no changes. Build ID: 3e14ee0b26b5817fab5d2812 |
commit: |
commit: |
size-limit report 📦
|
✅ Deploy Preview for apollo-client-docs ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
@@ -0,0 +1,175 @@ | |||
import typescriptEslint from "@typescript-eslint/eslint-plugin"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file was auto-migrated via npx @eslint/migrate-config .eslintrc
.
As a result I had to add the new dependencies @eslint/compat globals @eslint/js @eslint/eslintrc
@@ -77,7 +77,7 @@ const generateErrorMessage = (err: ApolloError) => { | |||
* | |||
* Use `ReadonlyArray<GraphQLFormattedError>` instead. | |||
*/ | |||
// eslint-disable-next-line @typescript-eslint/ban-types |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ban-types
has been removed and been split up into various new rules
@@ -1526,7 +1526,6 @@ describe("General Mutation testing", () => { | |||
// expect(waitFor(() => didError)).resolves.toBe(true); | |||
// | |||
// ...however it also causes the test to fail against React 17. | |||
// eslint-disable-next-line testing-library/await-async-utils |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure why that rule ever warned here, but it doesn't do that anymore.
@@ -9,6 +9,7 @@ export function useDeepMemo<TValue>( | |||
const ref = React.useRef<{ deps: DependencyList; value: TValue }>(void 0); | |||
|
|||
if (!ref.current || !equal(ref.current.deps, deps)) { | |||
// eslint-disable-next-line react-compiler/react-compiler |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New warnings on variables the compiler assumes immutable. I've added ignore comments for all of them.
@@ -190,12 +190,13 @@ export function useBackgroundQuery< | |||
] { | |||
return wrapHook( | |||
"useBackgroundQuery", | |||
_useBackgroundQuery, | |||
// eslint-disable-next-line react-compiler/react-compiler | |||
useBackgroundQuery_, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
_useBackgroundQuery
wasn't recognized as a "hook name" anymore, so I had to change it.
New rule on top: hooks cannot be saved into variables or passed as arguments. Generally I agree, but in this pattern it's okay.
@@ -5,7 +5,7 @@ import { | |||
invariant, | |||
} from "../invariantWrappers"; | |||
|
|||
function withDev() { | |||
function withDev(): typeof import("../../../dev") & AsyncDisposable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The AsyncDisposable
needs to be explicit.
@@ -49,4 +49,4 @@ export { Policies } from "./inmemory/policies.js"; | |||
export type { FragmentRegistryAPI } from "./inmemory/fragmentRegistry.js"; | |||
export { createFragmentRegistry } from "./inmemory/fragmentRegistry.js"; | |||
|
|||
export * from "./inmemory/types.js"; | |||
export type * from "./inmemory/types.js"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wildcard type-only exports should also contain type
, which seems like a good thing.
@@ -63,7 +63,7 @@ interface BaseOptions { | |||
// Warning: (ae-forgotten-export) The symbol "ApolloLink" needs to be exported by the entry point index.d.ts | |||
// | |||
// @public (undocumented) | |||
export const createPersistedQueryLink: (options: PersistedQueryLink.Options) => ApolloLink & { | |||
export const createPersistedQueryLink: (options: PersistedQueryLink.Options) => ApolloLink & ({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Additional ()
caused by api-explorer
update
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for doing this! This was long overdue.
This should address a lot of the updates in #11959
Also see the build output diff: https://github.com/apollographql/apollo-client/actions/runs/12888464243?pr=12286