Store normalized 💪

This commit is contained in:
Belen Curcio
2017-01-24 10:06:42 -03:00
parent c3f238b0b2
commit 9fd184f638
+6
View File
@@ -3,5 +3,11 @@ import getNetworkInterface from './transport';
export const client = new ApolloClient({
queryTransformer: addTypename,
dataIdFromObject: (result) => {
if (result.id && result.__typename) { // eslint-disable-line no-underscore-dangle
return result.__typename + result.id; // eslint-disable-line no-underscore-dangle
}
return null;
},
networkInterface: getNetworkInterface()
});