bluerain-apollo-plugin
Last updated
Last updated
A fully-featured, production ready caching GraphQL client for every server or UI framework.
🌏 Web
🖥 Electron
📱 React Native
✔️
✔️
TBD
NA
This plugin registers following components in the Component registry, so they can be reused later by other apps and plugins;
Apollo Consumer
GraphqlQuery
GraphqlMutation
GraphqlSubscription
This plugin provides complete flexibility to modify the apollo client. This is done by providing various filter hooks at different stages of store initialization.
This hook gives the ability to modify the main System App component that gets wrapped in Redux's Provider.
Name
Type
Description
SystemApp
React.Component
The main system app component.
Name
Type
Description
SystemApp
React.Component
The main system app component.
This example wraps the System App with a Apollo provider by using a replaceReduxProvider
higher order component (HOC).
This hook gives the ability to modify the plugin configurations.
Parameters:
Name
Type
Description
config
Object
Plugin configurations
Returns:
Name
Type
Description
config
Object
Plugin configurations
Example:
This example activates subscriptions in apollo client.
This hook gives the ability to provide uri for websocket server
Parameters:
Name
Type
Description
link
Array
uri for websocket server
Returns:
Name
Type
Description
link
Array
uri for websocket server
Example:
This Hook clears cache of the of Apollo store
This Hook Create apollo client when all plugins and apps are initialized
ApolloPluginConfigs
This is the default configuration set that is used at boot time.
Properties
httpLinkOptions HttpLinks URI link of websocket server
clientOptions
ApolloClientOptions Apollo client params
ApolloPlugin
Extends Plugin
Main Apollo Plugin class.
Plugin Properties
getClient
Returns Apollo client
pluginName
"ApolloPlugin"
slug
"apollo"