graphql-react
Advanced tools
Comparing version 11.0.3 to 11.0.4
# graphql-react changelog | ||
## 11.0.4 | ||
### Patch | ||
- Clearly documented ways to `import` and `require` the package exports. | ||
## 11.0.3 | ||
@@ -4,0 +10,0 @@ |
{ | ||
"name": "graphql-react", | ||
"version": "11.0.3", | ||
"version": "11.0.4", | ||
"description": "A GraphQL client for React using modern context and hooks APIs that is lightweight (< 3 KB size limited) but powerful; the first Relay and Apollo alternative with server side rendering.", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
120
readme.md
@@ -165,2 +165,22 @@ ![graphql-react logo](https://cdn.jsdelivr.net/gh/jaydenseric/graphql-react@0.1.0/graphql-react-logo.svg) | ||
_Ways to `import`._ | ||
> ```js | ||
> import { GraphQL } from 'graphql-react'; | ||
> ``` | ||
> | ||
> ```js | ||
> import GraphQL from 'graphql-react/universal/GraphQL.js'; | ||
> ``` | ||
_Ways to `require`._ | ||
> ```js | ||
> const { GraphQL } = require('graphql-react'); | ||
> ``` | ||
> | ||
> ```js | ||
> const GraphQL = require('graphql-react/universal/GraphQL'); | ||
> ``` | ||
_Construct a GraphQL client._ | ||
@@ -353,2 +373,22 @@ | ||
_Ways to `import`._ | ||
> ```js | ||
> import { GraphQLProvider } from 'graphql-react'; | ||
> ``` | ||
> | ||
> ```js | ||
> import GraphQLProvider from 'graphql-react/universal/GraphQLProvider.js'; | ||
> ``` | ||
_Ways to `require`._ | ||
> ```js | ||
> const { GraphQLProvider } = require('graphql-react'); | ||
> ``` | ||
> | ||
> ```js | ||
> const GraphQLProvider = require('graphql-react/universal/GraphQLProvider'); | ||
> ``` | ||
_Provide a [`GraphQL`](#class-graphql) instance for an app._ | ||
@@ -379,2 +419,22 @@ | ||
_Ways to `import`._ | ||
> ```js | ||
> import { reportCacheErrors } from 'graphql-react'; | ||
> ``` | ||
> | ||
> ```js | ||
> import reportCacheErrors from 'graphql-react/universal/reportCacheErrors.js'; | ||
> ``` | ||
_Ways to `require`._ | ||
> ```js | ||
> const { reportCacheErrors } = require('graphql-react'); | ||
> ``` | ||
> | ||
> ```js | ||
> const reportCacheErrors = require('graphql-react/universal/reportCacheErrors'); | ||
> ``` | ||
_[`GraphQL`](#class-graphql) initialized to report cache errors._ | ||
@@ -412,2 +472,22 @@ | ||
_Ways to `import`._ | ||
> ```js | ||
> import { ssr } from 'graphql-react/server'; | ||
> ``` | ||
> | ||
> ```js | ||
> import ssr from 'graphql-react/server/GraphQL.js'; | ||
> ``` | ||
_Ways to `require`._ | ||
> ```js | ||
> const { ssr } = require('graphql-react/server'); | ||
> ``` | ||
> | ||
> ```js | ||
> const ssr = require('graphql-react/server/ssr'); | ||
> ``` | ||
_SSR function that resolves a HTML string and cache JSON for client hydration._ | ||
@@ -479,2 +559,22 @@ | ||
_Ways to `import`._ | ||
> ```js | ||
> import { useGraphQL } from 'graphql-react'; | ||
> ``` | ||
> | ||
> ```js | ||
> import useGraphQL from 'graphql-react/universal/useGraphQL.js'; | ||
> ``` | ||
_Ways to `require`._ | ||
> ```js | ||
> const { useGraphQL } = require('graphql-react'); | ||
> ``` | ||
> | ||
> ```js | ||
> const useGraphQL = require('graphql-react/universal/useGraphQL'); | ||
> ``` | ||
_A component that displays a Pokémon image._ | ||
@@ -540,2 +640,22 @@ | ||
_Ways to `import`._ | ||
> ```js | ||
> import { GraphQLContext } from 'graphql-react'; | ||
> ``` | ||
> | ||
> ```js | ||
> import GraphQLContext from 'graphql-react/universal/GraphQLContext.js'; | ||
> ``` | ||
_Ways to `require`._ | ||
> ```js | ||
> const { GraphQLContext } = require('graphql-react'); | ||
> ``` | ||
> | ||
> ```js | ||
> const GraphQLContext = require('graphql-react/universal/GraphQLContext'); | ||
> ``` | ||
_A button component that resets the [GraphQL cache](#graphql-instance-property-cache)._ | ||
@@ -542,0 +662,0 @@ |
86513
988