1. 31 10月, 2019 1 次提交
  2. 28 3月, 2019 1 次提交
  3. 05 1月, 2019 1 次提交
  4. 31 1月, 2018 1 次提交
    • J
      [fix] apollo-redux: Separate out entire example #3463 (#3629) · ab889369
      Jerome Fitzgerald 提交于
      * [fix] apollo-redux: Separate out entire example #3463
      
      Apollo and Redux are completely separate ways of managing state. This example serves as a conduit if you were using Apollo 1.X with Redux, and are migrating to Apollo 2.x, however, you have chosen not to manage your entire application state within Apollo (`apollo-link-state`).
      
      There is no "withData" function that allows you to call either/or. You must call "withRedux" and/or "withApollo" on your Component. They can be combined in the example at `index.js` or remain separate as seen in `apollo.js` and `redux.js`.
      
      Going forward, this example may go the way of the dodo.
      
      * [chore] reformat code to match next syntax
      
      Localize prettier sometimes has a mind of its own. 😄️
      
      * Fix linting
      ab889369
  5. 28 12月, 2017 1 次提交
    • J
      [refactor] with-apollo-and-redux: 2.0.0 (#3484) · 46b57a6e
      Jerome Fitzgerald 提交于
      * [refactor] with-apollo-and-redux: 2.0.0
      
      - This ports over `with-apollo` (w/ recent `withRouter` fix and addition
      for Post) along with implementing `apollo-cache-redux` #3463
      - The `redux` side of things is lacking (it is the *same* as the
      original example)
      - Created a `routes.js` for use on Server and Client Side (to expand the
      PostList functionality)
      - SSR is maintained
      - Redid the "PostVote" a bit... sorry. 😬️
      
      Possible todo(s):
      - Add in API and Clock Examples from `with-redux` to show Apollo and
      Redux working together a bit more
      - redux-saga (I personally use this, may be too opinionated for the base
      example though)
      
      Packages updated:
      - apollo-cache-redux
      - apollo-client-preset
      - graphql
      - graphql-anywhere
      - graphql-tag
      - isomorphic-unfetch
      - next-routes
      - prop-types
      - react
      - react-apollo
      - react-dom
      - redux
      
      * [refactor] fix linting issues
      
      When I run `yarn lint` explicitly these were caught, but not doing a
      build proper. Apologies on that!
      
      * [chore] 📦️ package.json: like other examples
      
      * [refactor] +apollo-cache-inmemory, -apollo-cache-redux
      
      Separation of Apollo and Redux. 😄️
      We could stand to use a few actual examples of Redux, though this is a
      good starting block.
      Some other code cleanup as well.
      46b57a6e
  6. 23 11月, 2017 1 次提交
  7. 04 11月, 2017 1 次提交
  8. 19 10月, 2017 1 次提交
  9. 11 5月, 2017 1 次提交
  10. 03 4月, 2017 1 次提交
  11. 31 3月, 2017 1 次提交
    • A
      Create separate Apollo example without Redux integration (#1483) · c2036e13
      Adam Soffer 提交于
      * Add minimal apollo example
      
      * Update apollo example README
      
      * Update apollo example demo link in README
      
      * Fix button styles
      
      * Fix show more button
      
      * Alias demo url
      
      * Include the data field on the Apollo store when hydrating
      
      * Revert
      
      * Include the data field on the Apollo store when hydrating per tpreusse's suggestion.
      
      * Add example to faq section in README
      
      * Sort by newest; Add active state to buttons
      
      * Make optimization suggestions
      
      * Use process.browser; inline props
      
      * Pass wrapped component's initial props into component heirarchy if they exist
      
      * Remove unnecessary sorting of array
      
      * Update Apollo example
      
      * Remove trailing comma
      
      * Update reduxRootKey
      
      * Remove unnecessary babelrc
      
      * Update with-apollo example
      
      - Remove use of deprecated 'reduxRootKey' option
      - Add loading indicator inside pagination button
      
      * Fix with-apollo example pagination; Pass initialState to ApolloClient
      
      * Split apollo example into two (one with and without Redux integration)
      
      * Rename createClient private function to _initClient
      
      * Set initialState default parameter inside initClient function
      
      * Remove redux dep from with-apollo example
      c2036e13
  12. 12 3月, 2017 1 次提交
  13. 08 2月, 2017 1 次提交
  14. 22 1月, 2017 1 次提交
    • A
      Add Apollo example (#780) · 4b257483
      Adam Soffer 提交于
      * Add minimal apollo example
      
      * Update apollo example README
      
      * Update apollo example demo link in README
      
      * Fix button styles
      
      * Fix show more button
      
      * Alias demo url
      
      * Include the data field on the Apollo store when hydrating
      
      * Revert
      
      * Include the data field on the Apollo store when hydrating per tpreusse's suggestion.
      
      * Add example to faq section in README
      
      * Sort by newest; Add active state to buttons
      
      * Make optimization suggestions
      
      * Use process.browser; inline props
      4b257483
  15. 08 1月, 2017 1 次提交
  16. 22 12月, 2016 1 次提交
    • D
      Add/move examples (#470) · c5d69f05
      Dan Zajdband 提交于
      * Added redux and styled components (wip) examples.
      
      * Updated examples readmes and package.json
      
      * Fixed styled-components example
      c5d69f05
  17. 16 12月, 2016 1 次提交
    • A
      Prefetch pages with Service Workers (#375) · 36abdc77
      Arunoda Susiripala 提交于
      * Register the service worker.
      
      * Update prefetcher code to do prefetching.
      
      * Implement the core prefetching API.
      support "import <Link>, { prefetch } from 'next/prefetch'"
      
      * Implement a better communication system with the service worker.
      
      * Add a separate example for prefetching
      
      * Fix some typos.
      
      * Initiate service worker support even prefetching is not used.
      This is pretty important since initiating will reset the cache.
      If we don't do this, it's possible to have old cached resources
      after the user decided to remove all of the prefetching logic.
      In this case, even the page didn't prefetch it'll use the
      previously cached pages. That because of there might be a already running
      service worker.
      
      * Use url module to get pathname.
      
      * Move prefetcher code to the client from pages
      Now we also do a webpack build for the prefetcher code.
      
      * Add prefetching docs to the README.md
      
      * Fix some typo.
      
      * Register service worker only if asked to prefetch
      We also clean the cache always, even we initialize
      the service worker or not.
      36abdc77
  18. 02 12月, 2016 1 次提交
  19. 28 11月, 2016 1 次提交
    • A
      Add support for webpack's CommonsChunkPlugin and remove next bundle (#301) · fcd59ade
      Arunoda Susiripala 提交于
      * Add example app which demonstrate the problem.
      
      * Add the first working version.
      
      * Fix lint issues.
      
      * Add README.md
      
      * Use /_next/main.js as the main file URI
      
      * Add the support for loading the core next bundle.
      
      * Optimize the output by removing Next modules from pages.
      
      * Use the same package.json as master use.
      
      * Change the example repo's README for simpler instructions.
      
      * Change example projects package.json to support next build and start.
      
      * Change main.js into commons.js.
      
      * Add support for hot core reload and errors.
      
      * Introduce require based on eval-script.
      
      * Add error reporting support with hot reloading.
      
      * Update README.md
      fcd59ade