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

chore(deps): update renovate dependency scan #319

Merged
merged 1 commit into from
Oct 19, 2023
Merged

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented May 1, 2023

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence Type Update
@apollo/client (source) 3.7.13 -> 3.8.6 age adoption passing confidence dependencies minor
@babel/preset-env (source) 7.21.5 -> 7.23.2 age adoption passing confidence devDependencies minor
@opentelemetry/api (source) 1.4.1 -> 1.6.0 age adoption passing confidence dependencies minor
@opentelemetry/auto-instrumentations-node (source) ^0.36.0 -> ^0.39.0 age adoption passing confidence dependencies minor
@opentelemetry/exporter-zipkin (source) 1.12.0 -> 1.17.1 age adoption passing confidence dependencies minor
@testing-library/jest-dom 5.16.5 -> 5.17.0 age adoption passing confidence dependencies minor
@types/core-js (source) 2.5.5 -> 2.5.7 age adoption passing confidence devDependencies patch
@types/knockout (source) 3.4.72 -> 3.4.74 age adoption passing confidence dependencies patch
@types/node (source) 18.16.3 -> 18.18.6 age adoption passing confidence devDependencies minor
@types/requirejs (source) 2.1.34 -> 2.1.36 age adoption passing confidence dependencies patch
axios (source) 1.4.0 -> 1.5.1 age adoption passing confidence dependencies minor
babel-jest 29.5.0 -> 29.7.0 age adoption passing confidence devDependencies minor
body-parser 1.19.0 -> 1.20.2 age adoption passing confidence dependencies minor
bootstrap (source) 5.2.3 -> 5.3.2 age adoption passing confidence dependencies minor
cookie-parser 1.4.5 -> 1.4.6 age adoption passing confidence dependencies patch
expect 29.5.0 -> 29.7.0 age adoption passing confidence devDependencies minor
express (source) 4.17.1 -> 4.18.2 age adoption passing confidence dependencies minor
firebase (source, changelog) 9.21.0 -> 9.23.0 age adoption passing confidence dependencies minor
formik (source) 2.2.9 -> 2.4.5 age adoption passing confidence dependencies minor
graphql 15.5.1 -> 15.8.0 age adoption passing confidence dependencies minor
jsonwebtoken 9.0.0 -> 9.0.2 age adoption passing confidence dependencies patch
lowdb 6.0.0 -> 6.1.0 age adoption passing confidence dependencies minor
node 18.16.0 -> 18.18.2 age adoption passing confidence engines minor
nodemon (source) 2.0.12 -> 2.0.22 age adoption passing confidence devDependencies patch
nodemon (source) 2.0.12 -> 2.0.22 age adoption passing confidence dependencies patch
opentelemetry-resource-detector-service ^0.28.0 -> ^0.29.0 age adoption passing confidence dependencies minor
p5 1.6.0 -> 1.7.0 age adoption passing confidence dependencies minor
prettier (source) 2.3.2 -> 2.8.8 age adoption passing confidence devDependencies minor
properties-reader 2.2.0 -> 2.3.0 age adoption passing confidence devDependencies minor
react-router-dom 6.11.0 -> 6.17.0 age adoption passing confidence dependencies minor
rollup-plugin-svelte 7.1.4 -> 7.1.6 age adoption passing confidence devDependencies patch
rxfire (source) 6.0.3 -> 6.0.5 age adoption passing confidence dependencies patch
sequelize (source) 6.31.0 -> 6.33.0 age adoption passing confidence dependencies minor
svelte (source) 3.58.0 -> 3.59.2 age adoption passing confidence devDependencies minor
typescript (source) 5.0.4 -> 5.2.2 age adoption passing confidence dependencies minor
typescript (source) 5.0.4 -> 5.2.2 age adoption passing confidence devDependencies minor
uuid 9.0.0 -> 9.0.1 age adoption passing confidence dependencies patch
validator 13.9.0 -> 13.11.0 age adoption passing confidence dependencies minor

Release Notes

apollographql/apollo-client (@​apollo/client)

v3.8.6

Compare Source

Patch Changes
  • #​11291 2be7eafe3 Thanks @​ArioA! - Fix a bug that allows to only call loadErrorMessages without also calling loadDevErrorMessages.

  • #​11274 b29f000f3 Thanks @​jerelmiller! - Start the query ref auto dispose timeout after the initial promise has settled. This prevents requests that run longer than the timeout duration from keeping the component suspended indefinitely.

  • #​11289 b5894dbf0 Thanks @​phryneas! - MockedProvider: default connectToDevTools to false in created ApolloClient instance.

    This will prevent the mocked ApolloClient instance from trying to connect to the DevTools, which would start a setTimeout that might keep running after a test has finished.

  • #​11206 dd2ce7687 Thanks @​phryneas! - cache.modify: Less strict types & new dev runtime warnings.

v3.8.5

Compare Source

v3.8.4

Compare Source

Patch Changes

v3.8.3

Compare Source

Patch Changes

v3.8.2

Compare Source

Patch Changes
  • #​10072 51045c336 Thanks @​Huulivoide! - Fixes race conditions in useReactiveVar that may prevent updates to the reactive variable from propagating through the hook.

  • #​11162 d9685f53c Thanks @​jerelmiller! - Ensures GraphQL errors returned in subscription payloads adhere to the errorPolicy set in client.subscribe(...) calls.

  • #​11134 96492e142 Thanks @​alessbell! - Use separate type imports in useSuspenseQuery and useBackgroundQuery to workaround SWC compiler issue.

  • #​11117 6b8198109 Thanks @​phryneas! - Adds a new devtools registration mechanism and tweaks the mechanism behind the
    "devtools not found" mechanic.

  • #​11186 f1d429f32 Thanks @​jerelmiller! - Fix an issue where race conditions when rapidly switching between variables would sometimes result in the wrong data returned from the query. Specifically this occurs when a query is triggered with an initial set of variables (VariablesA), then triggers the same query with another set of variables (VariablesB) but switches back to the VariablesA before the response for VariablesB is returned. Previously this would result in the data for VariablesB to be displayed while VariablesA was active. The data is for VariablesA is now properly returned.

  • #​11163 a8a9e11e9 Thanks @​bignimbus! - Fix typo in error message: "occured" -> "occurred"

  • #​11180 7d9c481e5 Thanks @​jerelmiller! - Fixes an issue where refetching from useBackgroundQuery via refetch with an error after an error was already fetched would get stuck in a loading state.

v3.8.1

Compare Source

Patch Changes
  • #​11141 c469b1616 Thanks @​jerelmiller! - Remove newly exported response iterator helpers that caused problems on some installs where @types/node was not available.

    IMPORTANT

    The following exports were added in version 3.8.0 that are removed with this patch.

    • isAsyncIterableIterator
    • isBlob
    • isNodeReadableStream
    • isNodeResponse
    • isReadableStream
    • isStreamableBlob

v3.8.0

Compare Source

Minor Changes
Fetching with Suspense 🎉
  • #​10323 64cb88a4b Thanks @​jerelmiller! - Add support for React suspense with a new useSuspenseQuery hook.

    useSuspenseQuery initiates a network request and causes the component calling it to suspend while the request is in flight. It can be thought of as a drop-in replacement for useQuery that allows you to take advantage of React's concurrent features while fetching during render.

    Consider a Dog component that fetches and renders some information about a dog named Mozzarella:

    View code 🐶
    import { Suspense } from "react";
    import { gql, TypedDocumentNode, useSuspenseQuery } from "@​apollo/client";
    
    interface Data {
      dog: {
        id: string;
        name: string;
      };
    }
    
    interface Variables {
      name: string;
    }
    
    const GET_DOG_QUERY: TypedDocumentNode<Data, Variables> = gql`
      query GetDog($name: String) {
        dog(name: $name) {
          id
          name
        }
      }
    `;
    
    function App() {
      return (
        <Suspense fallback={<div>Loading...</div>}>
          <Dog name="Mozzarella" />
        </Suspense>
      );
    }
    
    function Dog({ name }: { name: string }) {
      const { data } = useSuspenseQuery(GET_DOG_QUERY, {
        variables: { name },
      });
    
      return <>Name: {data.dog.name}</>;
    }

    For a detailed explanation of useSuspenseQuery, see our fetching with Suspense reference.

  • #​10755 e3c676deb Thanks @​alessbell! - Feature: adds useBackgroundQuery and useReadQuery hooks

    useBackgroundQuery initiates a request for data in a parent component and returns a QueryReference which is used to read the data in a child component via useReadQuery. If the child component attempts to render before the data can be found in the cache, the child component will suspend until the data is available. On cache updates to watched data, the child component calling useReadQuery will re-render with new data but the parent component will not re-render (as it would, for example, if it were using useQuery to issue the request).

    Consider an App component that fetches a list of breeds in the background while also fetching and rendering some information about an individual dog, Mozzarella:

    View code 🐶
    function App() {
      const [queryRef] = useBackgroundQuery(GET_BREEDS_QUERY);
      return (
        <Suspense fallback={<div>Loading...</div>}>
          <Dog name="Mozzarella" queryRef={queryRef} />
        </Suspense>
      );
    }
    
    function Dog({
      name,
      queryRef,
    }: {
      name: string;
      queryRef: QueryReference<BreedData>;
    }) {
      const { data } = useSuspenseQuery(GET_DOG_QUERY, {
        variables: { name },
      });
      return (
        <>
          Name: {data.dog.name}
          <Suspense fallback={<div>Loading breeds...</div>}>
            <Breeds queryRef={queryRef} />
          </Suspense>
        </>
      );
    }
    
    function Breeds({ queryRef }: { queryRef: QueryReference<BreedData> }) {
      const { data } = useReadQuery(queryRef);
      return data.breeds.map(({ characteristics }) =>
        characteristics.map((characteristic) => (
          <div key={characteristic}>{characteristic}</div>
        ))
      );
    }

    For a detailed explanation of useBackgroundQuery and useReadQuery, see our fetching with Suspense reference.

Document transforms 📑
  • #​10509 79df2c7ba Thanks @​jerelmiller! - Add the ability to specify custom GraphQL document transforms. These transforms are run before reading data from the cache, before local state is resolved, and before the query document is sent through the link chain.

    To register a custom document transform, create a transform using the DocumentTransform class and pass it to the documentTransform option on ApolloClient.

    import { DocumentTransform } from "@&#8203;apollo/client";
    
    const documentTransform = new DocumentTransform((document) => {
      // do something with `document`
      return transformedDocument;
    });
    
    const client = new ApolloClient({ documentTransform: documentTransform });

    For more information on the behavior and API of DocumentTransform, see its reference page in our documentation.

New removeTypenameFromVariables link 🔗
  • #​10853 300957960 Thanks @​jerelmiller! - Introduce the new removeTypenameFromVariables link. This link will automatically remove __typename fields from variables for all operations. This link can be configured to exclude JSON-scalars for scalars that utilize __typename.

    This change undoes some work from #​10724 where __typename was automatically stripped for all operations with no configuration. This was determined to be a breaking change and therefore moved into this link.

    For a detailed explanation of removeTypenameFromVariables, see its API reference.

New skipToken sentinel ⏭️
  • #​11112 b4aefcfe9 Thanks @​jerelmiller! - Adds support for a skipToken sentinel that can be used as options in useSuspenseQuery and useBackgroundQuery to skip execution of a query. This works identically to the skip option but is more type-safe and as such, becomes the recommended way to skip query execution. As such, the skip option has been deprecated in favor of skipToken.

    We are considering the removal of the skip option from useSuspenseQuery and useBackgroundQuery in the next major. We are releasing with it now to make migration from useQuery easier and make skipToken more discoverable.

    useSuspenseQuery

    import { skipToken, useSuspenseQuery } from "@&#8203;apollo/client";
    
    const id: number | undefined;
    
    const { data } = useSuspenseQuery(
      query,
      id ? { variables: { id } } : skipToken
    );

    useBackgroundQuery

    import { skipToken, useBackgroundQuery } from "@&#8203;apollo/client";
    
    function Parent() {
      const [queryRef] = useBackgroundQuery(
        query,
        id ? { variables: { id } } : skipToken
      );
    
      return queryRef ? <Child queryRef={queryRef} /> : null;
    }
    
    function Child({ queryRef }: { queryRef: QueryReference<TData> }) {
      const { data } = useReadQuery(queryRef);
    }

    For a detailed explanation of skipToken, see its API reference.

New error extraction mechanism, smaller bundles 📉
  • #​10887 f8c0b965d Thanks @​phryneas! - Add a new mechanism for Error Extraction to reduce bundle size by including error message texts on an opt-in basis.

    By default, errors will link to an error page with the entire error message.
    This replaces "development" and "production" errors and works without
    additional bundler configuration.

    Bundling the text of error messages and development warnings can be enabled as follows:

    import { loadErrorMessages, loadDevMessages } from "@&#8203;apollo/client/dev";
    if (process.env.NODE_ENV !== "production") {
      loadErrorMessages();
      loadDevMessages();
    }

    For a detailed explanation, see our reference on reducing bundle size.

New @nonreactive directive 🎬
  • #​10722 c7e60f83d Thanks @​benjamn! - Implement a @nonreactive directive for selectively skipping reactive comparisons of query result subtrees.

    The @nonreactive directive can be used to mark query fields or fragment spreads and is used to indicate that changes to the data contained within the subtrees marked @nonreactive should not trigger re-rendering. This allows parent components to fetch data to be rendered by their children without re-rendering themselves when the data corresponding with fields marked as @nonreactive change.

    Consider an App component that fetches and renders a list of ski trails:

    View code 🎿
    const TrailFragment = gql`
      fragment TrailFragment on Trail {
        name
        status
      }
    `;
    
    const ALL_TRAILS = gql`
      query allTrails {
        allTrails {
          id
          ...TrailFragment @&#8203;nonreactive
        }
      }
      ${TrailFragment}
    `;
    
    function App() {
      const { data, loading } = useQuery(ALL_TRAILS);
      return (
        <main>
          <h2>Ski Trails</h2>
          <ul>
            {data?.trails.map((trail) => (
              <Trail key={trail.id} id={trail.id} />
            ))}
          </ul>
        </main>
      );
    }

    The Trail component renders a trail's name and status and allows the user to execute a mutation to toggle the status of the trail between "OPEN" and "CLOSED":

    View code 🎿
    const Trail = ({ id }) => {
      const [updateTrail] = useMutation(UPDATE_TRAIL);
      const { data } = useFragment({
        fragment: TrailFragment,
        from: {
          __typename: "Trail",
          id,
        },
      });
      return (
        <li key={id}>
          {data.name} - {data.status}
          <input
            checked={data.status === "OPEN" ? true : false}
            type="checkbox"
            onChange={(e) => {
              updateTrail({
                variables: {
                  trailId: id,
                  status: e.target.checked ? "OPEN" : "CLOSED",
                },
              });
            }}
          />
        </li>
      );
    };

    Notice that the Trail component isn't receiving the entire trail object via props, only the id which is used along with the fragment document to create a live binding for each trail item in the cache. This allows each Trail component to react to the cache updates for a single trail independently. Updates to a trail's status will not cause the parent App component to rerender since the @nonreactive directive is applied to the TrailFragment spread, a fragment that includes the status field.

    For a detailed explanation, see our @nonreactive reference and @​alessbell's post on the Apollo blog about using @nonreactive with useFragment.

Abort the AbortController signal more granularly 🛑
  • #​11040 125ef5b2a Thanks @​phryneas! - HttpLink/BatchHttpLink: Abort the AbortController signal more granularly.

    Before this change, when HttpLink/BatchHttpLink created an AbortController internally, the signal would always be .aborted after the request was completed. This could cause issues with Sentry Session Replay and Next.js App Router Cache invalidations, which just replayed the fetch with the same options - including the cancelled AbortSignal.

    With this change, the AbortController will only be .abort()ed by outside events, not as a consequence of the request completing.

useFragment drops its experimental label 🎓
  • #​10916 ea75e18de Thanks @​alessbell! - Remove experimental labels.

    useFragment, introduced in 3.7.0 as useFragment_experimental, is no longer an experimental API 🎉 We've removed the _experimental suffix from its named export and have made a number of improvements.

    For a detailed explanation, see our useFragment reference and @​alessbell's post on the Apollo blog about using useFragment with @nonreactive for improved performance when rendering lists.

    useFragment improvements
    • #​10765 35f36c5aa Thanks @​phryneas! - More robust types for the data property on UseFragmentResult. When a partial result is given, the type is now correctly set to Partial<TData>.

    • #​11083 f766e8305 Thanks @​phryneas! - Adjust the rerender timing of useQuery to more closely align with useFragment. This means that cache updates delivered to both hooks should trigger renders at relatively the same time. Previously, the useFragment might rerender much faster leading to some confusion.

    • #​10836 6794893c2 Thanks @​phryneas! - Remove the deprecated returnPartialData option from useFragment hook.

More Minor Changes

  • #​10895 e187866fd Thanks @​Gelio! - Add generic type parameter for the entity modified in cache.modify. Improves TypeScript type inference for that type's fields and values of those fields.

    Example:

    cache.modify<Book>({
      id: cache.identify(someBook),
      fields: {
        title: (title) => {
          // title has type `string`.
          // It used to be `any`.
        },
     => {
          // author has type `Reference | Book["author"]`.
          // It used to be `any`.
        },
      },
    });
  • #​10895 e187866fd Thanks @​Gelio! - Use unique opaque types for the DELETE and INVALIDATE Apollo cache modifiers.

    This increases type safety, since these 2 modifiers no longer have the any type. Moreover, it no longer triggers the @typescript-eslint/no-unsafe-return
    rule
    .

  • #​10340 4f73c5ca1 Thanks @​alessbell! - Avoid calling useQuery onCompleted for cache writes

  • #​10527 0cc7e2e19 Thanks @​phryneas! - Remove the query/mutation/subscription option from hooks that already take that value as their first argument.

  • #​10506 2dc2e1d4f Thanks @​phryneas! - prevent accidental widening of inferred TData and TVariables generics for query hook option arguments

  • #​10521 fbf729414 Thanks @​benjamn! - Simplify __DEV__ polyfill to use imports instead of global scope

  • #​10994 2ebbd3abb Thanks @​phryneas! - Add .js file extensions to imports in src and dist/*/.d.ts

  • #​11045 9c1d4a104 Thanks @​jerelmiller! - When changing variables back to a previously used set of variables, do not automatically cache the result as part of the query reference. Instead, dispose of the query reference so that the InMemoryCache can determine the cached behavior. This means that fetch policies that would guarantee a network request are now honored when switching back to previously used variables.

  • #​11058 89bf33c42 Thanks @​phryneas! - (Batch)HttpLink: Propagate AbortErrors to the user when a user-provided signal is passed to the link. Previously, these links would swallow all AbortErrors, potentially causing queries and mutations to never resolve. As a result of this change, users are now expected to handle AbortErrors when passing in a user-provided signal.

  • #​10346 [3bcfc42d3](https://togithub.com/apollographql/apollo-client/commit/3bcfc42d394b6a97900495eacdaf58c


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate. View repository job log here.

@renovate renovate bot force-pushed the renovate/all branch 9 times, most recently from 0e05251 to ce3a63e Compare May 10, 2023 09:47
@renovate renovate bot force-pushed the renovate/all branch 9 times, most recently from 15bbfd8 to 7c38530 Compare May 17, 2023 15:42
@renovate renovate bot force-pushed the renovate/all branch 5 times, most recently from 9538b15 to 8782c76 Compare May 24, 2023 23:07
@renovate renovate bot force-pushed the renovate/all branch 7 times, most recently from 4f0a1db to 364bd75 Compare May 29, 2023 15:29
@renovate renovate bot force-pushed the renovate/all branch 5 times, most recently from aae7e75 to 6cb491e Compare September 25, 2023 23:16
@renovate renovate bot force-pushed the renovate/all branch 7 times, most recently from edfd5aa to 75fbd51 Compare October 2, 2023 21:22
@renovate renovate bot force-pushed the renovate/all branch 6 times, most recently from cf8098a to 933f76c Compare October 11, 2023 19:42
@renovate renovate bot force-pushed the renovate/all branch 9 times, most recently from ae288ba to d2d2fe3 Compare October 18, 2023 17:08
@saurabhpro saurabhpro merged commit 44ef652 into master Oct 19, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant