react-apollo v2.2.3 Release Notes

Release Date: 2018-09-30 // over 5 years ago
  • ๐Ÿ› Bug Fixes

    • Mutation errors are now properly returned as a render prop, when using a default errorPolicy of all. @amacleay in #2374
    • <Mutation /> refetchQueries triggered by name (string) will now use the correct variables. @fracmal in #2422

    ๐Ÿ‘Œ Improvements

    • Replace the lodash dependency with lodash.flowright (since that's the only non-dev lodash function we're dependent on). Dev lodash dependencies have also been updated to use their individual module equivalent. @hwillson in #2435
    • โœ‚ Removed rollup-plugin-babel-minify as it's no longer being used. @hwillson in #2436
    • Small getDataFromTree.ts logic adjustment to avoid unnecessary calls when a falsy element is encountered. @HOUCe in #2429
    • โšก๏ธ graphql 14 updates. @hwillson in #2437
    • โšก๏ธ All example apps (included in the repo) have been updated to work with the latest version of React Apollo. @hwillson in #2439

    Typescript

    • ๐Ÿ›  Fix lodash typings. @williamboman in #2430
    • Typings: added context to MutationOptions. @danilobuerger in #2354
    • ๐Ÿ›  Typings: more MutationOptions changes/fixes. @danilobuerger in #2340
    • โœ‚ Remove allowSyntheticDefaultImports use. Typescript's allowSyntheticDefaultImports compiler option is something we'd like to start using, but we jumped the gun a bit by introducing it in https://github.com/apollographql/react-apollo/commit/9a96519d390783dfd9a431dc2dbaa476a24f7b80. Including it means that anyone who wants to use Typescript with React Apollo would have to also include it in their own local tsconfig.json, to be able to handle default imports properly. This is because we're also using Typescript's es2015 module option, which means allowSyntheticDefaultImports has to be enabled explicitly. We've switched back to using a combination of import * as X and require syntax, to work with default imports. We'll re-introduce allowSyntheticDefaultImports use in React Apollo 3. @hwillson in #2438