All Projects β†’ abhiaiyer91 β†’ recompose-apollo

abhiaiyer91 / recompose-apollo

Licence: other
Recompose HOCs for React Apollo

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to recompose-apollo

react-apollo-fragments
True Fragment component for react-apollo
Stars: ✭ 13 (-63.89%)
Mutual labels:  apollo-client, react-apollo
React Graphql Github Apollo
πŸš€ A React + Apollo + GraphQL GitHub Client. Your opportunity to learn about these technologies in a real world application.
Stars: ✭ 1,563 (+4241.67%)
Mutual labels:  apollo-client, react-apollo
talktalk-rn
(Deprecated via hackatalk-mobile) talktalk app built in react-native.
Stars: ✭ 31 (-13.89%)
Mutual labels:  apollo-client
babel-plugin-flow-relay-query
Babel plugin which converts Flow types into Relay fragments
Stars: ✭ 38 (+5.56%)
Mutual labels:  apollo-client
GithubClient
Github iOS Client based on Github REST V3 API and GraphQL V4 API
Stars: ✭ 42 (+16.67%)
Mutual labels:  apollo-client
ReactNativeApolloOnlineStore
A react native online shop using Apollo client 3
Stars: ✭ 60 (+66.67%)
Mutual labels:  apollo-client
realworld
"The mother of all demo apps" β€” Exemplary fullstack Medium.com clone powered by Next.js and Ruby on Rails πŸ…
Stars: ✭ 113 (+213.89%)
Mutual labels:  apollo-client
friendly-vue-starter
Full featured Vue.js starter project for browser apps
Stars: ✭ 37 (+2.78%)
Mutual labels:  apollo-client
les-chat
Real-time messenger with private, public & group chat. Made using PERN + GraphQL stack.
Stars: ✭ 48 (+33.33%)
Mutual labels:  apollo-client
ctrip-apollo-client
This is a client library for Apollo(A reliable configuration management system) written in Node.js.
Stars: ✭ 49 (+36.11%)
Mutual labels:  apollo-client
dribbble-clone
FullStack GraphQL Dribbble Clone πŸ€
Stars: ✭ 29 (-19.44%)
Mutual labels:  apollo-client
apollo-resolvers
Expressive and composable resolvers for Apollostack's GraphQL server
Stars: ✭ 434 (+1105.56%)
Mutual labels:  apollo-client
react-graphql
react-graphql εΏ«ι€ŸεΌ€ε‘ζ–Ήζ‘ˆ
Stars: ✭ 15 (-58.33%)
Mutual labels:  apollo-client
cash-flow
Application for managing cash flows written in ASP.NET Core 6 and Angular 13 (EF Core, Apollo, GraphQL, CQRS)
Stars: ✭ 27 (-25%)
Mutual labels:  apollo-client
Gatsby-Starter-Typescript-Apollo-Storybook
Starter with the bare essentials needed for a typescript, apollo, storybook, emotion Gatsby site
Stars: ✭ 17 (-52.78%)
Mutual labels:  apollo-client
apollo-errors
Machine-readable custom errors for Apollostack's GraphQL server
Stars: ✭ 408 (+1033.33%)
Mutual labels:  apollo-client
graphql-workshop
βš’ 🚧 A GraphQL workshop to learn GraphQL implementations
Stars: ✭ 20 (-44.44%)
Mutual labels:  apollo-client
mobile
🀳 React Native code examples for JavaScript Everywhere by Adam Scott, published by O'Reilly Media
Stars: ✭ 33 (-8.33%)
Mutual labels:  apollo-client
react-apollo-graphql
Get rid of decorators and use Apollo GraphQL queries and mutations in the simple and readable way.
Stars: ✭ 16 (-55.56%)
Mutual labels:  apollo-client
UmaSupporter.WebClient
πŸƒπŸ½β€β™€οΈ μš°λ§ˆλ¬΄μŠ€λ©” μœ‘μ„± λ„μš°λ―Έ 'μš°λ§ˆμ„œν¬ν„°'의 ν”„λ‘ νŠΈμ—”λ“œ μ• ν”Œλ¦¬μΌ€μ΄μ…˜μž…λ‹ˆλ‹€.
Stars: ✭ 14 (-61.11%)
Mutual labels:  apollo-client

Recompose Apollo

a utility belt for higher-order components in apollo. Recompose utilities for react-apollo.

Higher-order components

withQueryData()

withQueryData(
  queryDocument: DocumentNode,
  optionsObject: { options: (props) => { variables } } | { options: Object }
): HigherOrderComponent

Same functionality as react-apollo graphql HOC, except the data prop or named data prop is flattened.

withQueryComponent()

withQueryComponent(
  queryDocument: DocumentNode,
  optionsObject: { options: (props) => { variables } } | { options: Object }
): Component

Return a query component given a GraphQL document and options. What's returned is a Component with a render child that has the data object from react-apollo, see below.

Query Components outlined: https://dev-blog.apollodata.com/query-components-with-apollo-ec603188c157

const CitiesQuery = withQueryComponent(cityQuery);

function Sample() {
  return (
    <CitiesQuery>
      {
        (data) => {
          return (
            <p> I am loading {data.loading ? 'Yes' : 'No'} </p>
          );
        }
      }
    </CitiesQuery>
  );
}

withFragment()

withFragment(
  fragmentDocument: DocumentNode,
  optionsObject: {
    name: string,
    getFragmentId: (props) => string,
  }
): HigherOrderComponent

After a query has been made with the graphql HOC, use this HOC to read fragments from the Apollo Client cache. Based on the options name, the fragment data will be returned to the component as props under that key or data.

withSubscribe()

withSubscribe(
  subscriptionDocument: DocumentNode,
  optionsObject: { options: (props) => { variables } }
): HigherOrderComponent

Create a GraphQL subscription that subscribes on componentDidMount. By providing a onResult prop to the Component, every time the subscription yields next, onResult will be called with the result of the subscription.

withLoadingState()

withLoadingState(
  Component: Function,
): HigherOrderComponent

Render a Component if the networkStatus from apollo-client is loading, otherwise return props for networkStatus:

  • activelyRefetching
  • passivelyRefetching
  • fetchingMore

withErrorState()

withErrorState(
  Component: Function,
): HigherOrderComponent

Render a Component if the networkStatus from apollo-client is error.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].