- [babel-plugin, core] adds an option to babel-plugin to generate an id side by side with the query in Grafoo Object. This feature will enable persistent queries in the future.
- [core] add reset method to client to clear the cache.
- [babel-plugin] Correctly identify variables in arguments
- [babel-plugin] Don't throw error when encountering a Union node
- [babel-plugin] Prevent multiple instances of idFields to be added to the same node in a query
- [babel-plugin] allow schema to be omited on config
- [babel-plugin] fix client factory throwing when called with a variable as the second argument
- [preact] fix variables not being updated
- [bindings] enable load method to receive and update variables
- [core] fix bug preventing write to work when graphql payload wasn't destructured beforehand
- [bindings] for safety reusing
props
argument to avoid declaration of new variables
- [react, preact] reload when variables change
- [preact] correctly type children prop
- [core] fix latest bug that afected also
client.read
- [core] allow queries to be partially cached on
client.write
- [preact, react] reload query on skip
Consumer
prop change to true
- [preact] fix preact not rendering on nested componenents when data have been already received
- [core] return a
partial
property in read to flag if a query result is only partially cached
- [bindings] fix bindings returning
loaded
equals to true if a query is only partially cached
- [bindings, react, preact] revert latest release reintroducing
loaded
prop from bindings
- [bindings, react, preact] remove
loaded
prop from bindings
- [core] transport logic has been removed from core. This is a breaking change and here is the fix:
import createClient from "@grafoo/core";
+ function fetchQuery(query, variables) {
+ const init = {
+ method: "POST",
+ body: JSON.stringify({ query, variables }),
+ headers: {
+ "content-type": "application/json"
+ }
+ };
+
+ return fetch("http://some.graphql.api", init).then(res => res.json());
+ }
- const client = createClient("http://some.graphql.api");
+ const client = createClient(fetchQuery);
- [core, transport] allow other fetch options to be set other then headers
- building packages locally
- last failed attempt to install packages on local install
- [babel-plugin] add @babel/cli
- fix further packages dependencies
- [bundle] add mri to package dependecies
- add coverage to packages .npmignore
- [core] fix objects not being cleaned from the cache on removal
- [bindings] fix block scope bug due to the use of var instead of let
- [babel-plugin] fix fragments not being compiled correctly in babel-plugin;
- [bindings] fix shouldupdate logic in bindings
- [babel-plugin] fix bug the was preventing fragments to be compiled in babel-plugin
sort-query
- [babel-plugin] improve coverage
- [react] same as before but now it's working
- [react] fix a bug that was preventing component setState to work within the consumer render function
- replace
@babel/preset-typescript
for rollup-plugin-typescript2
in grafoo-bundle
- bindings generated mutation functions now resolve with the mutation response
- bindings mutations
prop
does not require the update hook anymore
- bindings
loading
flag is always false whenever the load
is triggered