React Relay Offline Versions Save

TypeScript library files for Relay Modern Offline

v5.0.0

2 years ago

Improved

v4.0.0

3 years ago

With the release v11.0.2 important changes have been made to the internal relay api.

Improved

  • update relay dependency
  • update wora dependencies https://github.com/morrys/wora/pull/83
  • renamed fetchQuery to fetchQuery_DEPRECATED, now fetchQuery is an observable so the user must be sure the environment is hydrated before using it

Breaking change

  • migration to the new fetchQuery

before:

import { fetchQuery} from 'react-relay-offline';
queryProps = await fetchQuery<any>(
        environment,
        query,
        variables,
      )

after:

import { fetchQuery} from 'relay-runtime';
      if(!environment.isRehydrated()) {
        await environment.hydrate();
      }
      queryProps = await fetchQuery<any>(
        environment,
        query,
        variables,
      ).toPromise()

v3.2.0

3 years ago

Improved

v3.1.0

3 years ago

Improved / Breaking Change

  • bumping AsyncStorage (update wora/cache-persist dependency v2.2.0)
    • @react-native-community/async-storage is now deprecated, now you need to use @react-native-async-storage/async-storage

Fixed

v3.0.0

3 years ago

Improved

  • support relay v10
  • update relay-hooks 4.0.0

Breaking Change

  • removed QueryRenderer HOC
  • removed online & cache property from useQuery return
  • moved the TTL property from queryOptions to networkCacheConfig

I recommend reading the release notes for relay-hooks and wora / relay-store: https://github.com/relay-tools/relay-hooks/releases/tag/v4.0.0 https://github.com/morrys/wora/releases/tag/relay-store%404.0.0

v2.3.0

3 years ago

Improved

  • added loadQuery / loadLazyQuery / usePreloadedQuery functionality in order to implement the new render-as-you-fetch pattern in offline mode #54 #56
  • better typing
  • upgrade relay-hooks dependency
  • added useLazyLoadQuery hooks
  • added online prop to QueryRenderer render function and in hooksProps returned by useQuery, useLazyLoadQuery, usePreloadedQuery #19

v2.2.0

4 years ago

Improved

  • moved fetch query in wora/relay-offline
  • update wora dependencies:

wora/relay-offline

issues: https://github.com/morrys/react-relay-offline/issues/44 https://github.com/morrys/react-relay-offline/issues/6 https://github.com/morrys/react-relay-offline/issues/30

Improved

  • added fetchQuery
  • persist cacheConfig in offlineProcess, thanks to this PR facebook/relay#2937, now you can change network behavior directly from mutations

Fixed

  • fix retain typing
  • fix StoreOptions in EnvironmentIDB

wora/relay-store

Improved

  • added StoreOptions type
  • backward compatibility in GC (relay-store 2.x)

v2.1.0

4 years ago

Improved

v2.0.0

4 years ago

react-relay-offline https://github.com/morrys/react-relay-offline/issues/34

  • optimize store request identifier https://github.com/facebook/relay/pull/2985
    • at the moment I have solved the problem in @ wora/relay-store
  • support relay v8.0.0 & v9.0.0
  • upgrade relay-hooks
  • check the compatibility between the query TTL and the new Relay store data invalidation feature
  • added tests in react-relay-offline
  • eslint & prettier
  • CI action
  • release wora/relay-offline & wora/relay-store
  • upgrade wora/relay-offline & wora/relay-store
  • update the sample projects

relay-store

  • add tests
  • compatibility between the query TTL and the new Relay store data invalidation feature
  • optimize store request identifier
  • upgrade relay-runtime 9.0.0

relay-offline

  • update dependencies
  • expose mutateOffline function
  • fix offline options type
  • upgrade relay-runtime 9.0.0
  • add tests