Skip to content
This repository has been archived by the owner on Dec 30, 2022. It is now read-only.

fix(deps): update dependency next to v9 #2638

Merged
merged 1 commit into from Jul 8, 2019

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Jul 8, 2019

This PR contains the following updates:

Package Type Update Change
next (source) dependencies major 8.1.0 -> 9.0.0

Release Notes

zeit/next.js

v9.0.0

Compare Source

Major
  • Remove withAmp and do not expose isInAmpMode: #​7690
Minor
  • Add Typescript compilation: #​7110
  • Add support for /public: #​7213
  • Add API routes support: #​7296
  • Make next/dynamic loading component return null by default: #​7695
  • Automatic static optimization: #​7666
Patches
  • Add declaration files to /dist: #​7118
  • Updated broken test in Windows: #​7124
  • Add AMP label to AMP only pages in build tree: #​7123
  • More Specific Info on Script Loading Error: #​7108
  • Make next export respect experimental.exportTrailingSlash: #​6752
  • Add more TypeScript types: #​7054
  • Rewrote .circleci/config.yml to 2.1 schema: #​7103
  • Wait for entry to resolve in production build: #​7104
  • Fix: add repository to next-server package.json: #​7105
  • Update types for with-router: #​7106
  • Replace the typescript compiler with @​babel/preset-typescript: #​7016
  • Revert "Detect built ins in externals " (#​7107): #​7083
  • Update removing AMP pages to not require during build: #​7081
  • Make styles compatible in AMP mode: #​7060
  • Cache Babel and AutoDll plugin in dirDir/cache: #​7102
  • Remove un-needed config from example: #​7055
  • Update AMP example: #​7056
  • Update AMP example to AMP-first wording: 5499652
  • Update dependency to fix with-next-page-transitions example: #​7049
  • Add test for /dashboard/index: #​7065
  • With-apollo example: explicitly pass fetch to HttpLink: #​7072
  • Update fela example: #​7051
  • Disable Terser loader when debugging: #​7079
  • Fix broken link: #​7087
  • Upgrade with-reasonml example to Reason React 0.7 and JSX 3: #​7078
  • Update the recommendation section in examples/with-reasonml: #​7089
  • Run optimizer after validating in dirty AMP mode: #​7063
  • Detect built ins in externals: #​7083
  • Move react-ssr-prepass import inside of: #​7095
  • Export 404 even if undefined in exportPathMap: #​6912
  • Remove dynamic-import-node from the preset: #​7096
  • Update to share HMR and ondemand SSE connection: #​7084
  • Upgrade Terser: #​6981
  • Upgrade amp-optimizer to 0.5.3: #​7134
  • Add .d.ts for next-server: #​7133
  • Always use AllModulesIdentifiedPlugin after HashedModuleIdsPlugin: #​7138
  • TypeScript preset should always be enabled: #​7137
  • Remove old debugging logs: #​7139
  • A webpack bug is preventing us from hashing chunks: #​7142
  • Don&#​39;t re-use the same page file for error-recovery tests: #​7144
  • Add --target serverless flag: #​7141
  • Move generating types to before deploy: #​7145
  • Replace --target serverless with env var: #​7146
  • Move type generating: #​7147
  • Remove list_dist from debugging: #​7148
  • Remove type defs for non-ts files and fix wrong import for router in _app: #​7150
  • Add stale-while-revalidate when no getInitialProps: #​7149
  • Update to render directly to body in AMP mode: #​7151
  • Add support for .ts / .tsx import without extension: #​7152
  • Add missing property types for styled-jsx: #​7154
  • Add types for next/dynamic: #​7157
  • Add types for next/link: #​7160
  • Add missing .d.ts for next/dynamic: #​7158
  • Add warning for @​zeit/next-typescript: #​7163
  • Prefer type over interface: #​7164
  • Reduce CircleCI Parallelism: #​7171
  • Run Prettier on webpack configuration: #​7172
  • Don&#​39;t resolve ts|tsx for non-TypeScript users: #​7173
  • Update Prettier configuration: 00e8ba4
  • Add types for getInitialProps: #​7162
  • Make sure to 404 for AMP client bundles in dev mode: #​7183
  • Update cache-control header when no getInitialProps: #​7185
  • Improve contributing guide: #​7186
  • Fix missing webpack buildin: #​7187
  • Allow _app and _document to be extended with other props: #​7184
  • Make sure not to require react before NODE_ENV has been set: #​7200
  • Browserstack optimisations: #​7201
  • Make sure Cache-Control header is set when no getInitialProps: #​7202
  • Fix firefox bug with detecting instanceof Promise in dynamic: #​7203
  • Add theme to styled-components example: #​7206
  • Fix wrong task name on watch for next/export files: #​7204
  • Use intersection observer to preload in viewport: #​7196
  • Create CODE_OF_CONDUCT.md: #​7207
  • Use modern syntax in Next client code (e.g. async await): #​7014
  • Clean up code/testing artifacts from #​7014: #​7211
  • Make sure next-head class isn&#​39;t added to title: #​7214
  • Add stats to build tree: #​7194
  • Clear stale files from Next.js&#​39; babel-loader cache: #​7221
  • Fix missing injectCaller: #​7223
  • Remove unnecessary type from LinkProps: #​7233
  • Update webpack to 4.30.0: #​7238
  • Fix default meta tag being added in AMP mode: #​7248
  • Tweak ReasonML example: #​7254
  • Fix webpack fetch error: #​7253
  • Make sure to update asPath on hashOnlyChange to: #​7255
  • Remove reload and use only location.reload: #​7257
  • Update to latest version of browserstack-local: #​7236
  • Fix application output: #​7264
  • Add docs to public: #​7239
  • Fix attempting to observe non-DOM refs in Link: #​7249
  • Add test for invalid ref in Link: #​7266
  • Renamed IContext to be NextPageContext: #​7272
  • With apollo auth proxy: #​7165
  • Fix FOUC issue on with-fela example: #​7229
  • Add example with babel-plugin-react-css-modules: #​7219
  • Revert migrating babel-loader into Next.js: #​7265
  • Remove components from client router: #​7281
  • Integrate type checking into compilation pipeline: #​7278
  • Add initial docs for TypeScript: #​7169
  • Merged with-jest and with-flow examples into a new with-jest-flow example.: #​7224
  • Removed unusable React importing in _document.tsx and added esModuleInterop:true in tsconfig.json: #​7232
  • Add automatic TypeScript setup: #​7125
  • Update styling of TypeScript config: 37ebd61
  • Format chunk graph plugin: 92cbe13
  • Separate shared shuttle modules: #​7287
  • Update readme to use @​next/mdx: #​7291
  • Re-add prefetch prop type with deprecated: #​7292
  • Make sure API routes are built in production: #​7306
  • Fix:5049 Make Count in with-reasonml persist in runtime: #​7302
  • Demonstrate how to use kea actions in getInitialProps for server side rendering with state transferred to client-side: #​7298
  • Fix:7271 with-rematch - make sever rendered user list persist: #​7308
  • Fix POST and PUT on api routes: #​7319
  • Update the with-graphql-react example.: #​7317
  • Redesigned page output: #​7324
  • Fix windows backslashes not being replaced when identifying AMP pages: #​7331
  • Update with-styletron example, add debug mode and useStyletron: #​7290
  • Update typescript example to reflects out of box usage: #​7235
  • Fix error overlay dismiss after fixing build error: #​7335
  • Remove allowSyntheticDefaultImports in favor of esModuleInterop: #​7338
  • Anchor TypeScript check to fix invalid detection: #​7349
  • Updated typescript examples: #​7337
  • [with-loading] changed non-existent-page link to <a> tag: #​7350
  • Update 8.Question_about_next.md: #​7357
  • Show helpful warning when @​types/react isn&#​39;t found: #​7345
    #​7362
  • Add with-sentry-simple example.: #​7360
  • Add retrying to CircleCi and fixes for ncc&#​39;ed webpack: #​7366
  • [custom-server-typescript] remove outdir line from tsconfig.server.json:
  • Re-add retrying tests in CircleCi to prevent false failures: #​7374
  • Fix broken link: #​7378
  • Remove outdated "extras" section in with-tailwindcss example README: #​7379
  • Reduce the maximum number of shuttles: 931cd3d
  • Fix string type on router.query: #​7387
  • [with-typescript] Remove obsolete TypeScript plugin and updated readme: #​7368
  • Update to latest webpack-bundle-analyzer: #​7389
  • Document useAmp in readme: #​7405
  • Add auto static/dynamic: #​7293
  • Make sure rendering behavior is only changed when autoExport is enabled: #​7408
  • Upgrade dependencies: #​7412
  • Revert fs-extra upgrade due to issue in latest version with jest: #​7414
  • [custom-server-typescript] fixed custom server build issues: #​7385
  • Types description: #​7217
  • Don&#​39;t load from serverless in dev mode: #​7416
  • Create with-redux-persist example: #​7375
  • [with-reasonml] Show both internal and shared state managment.: #​7312
  • New Example: with-reasonml-todo(#​7346): 43dcb59
  • Add document middleware: #​7209
  • Opt out of cache header if _app has custom getInitialProps: #​7409
  • Refactor server router: #​7431
  • Fix duplicate dynamic chunks: #​7425
  • Update Tailwind CSS to v1.0: #​7421
  • Dynamic routing mark 2: #​7432
  • Remove deploy to now button from all examples: #​7101
  • Allow passing of title to default error page: #​7381
  • Implement UI to show building activity: #​6526
  • Update styles on build indicator container: #​7436
  • Fixed typo in README.md: #​7438
  • Bundle only server code for API routes: #​7443
  • Improvements to build watcher: #​7441
  • Enable strict export presence in webpack: #​7446
  • Add tests for build activity indicator: #​7448
  • Run lint-fix: c7276bc
  • Add amp.canonicalBase option to set absolute URL: #​7262
  • Do not force noEmit option into TypeScript configuration: #​7451
  • Correctly pass props down in with-lingui example HOC: #​7445
  • Move syntax formatting to prettier: #​7454
  • Remove react-ssr-prepass as it’s only needed for experimental feature: #​7455
  • Disable optional param routing code paths: #​7459
  • Don&#​39;t run standard for tsx files in husky to match lint-fix: #​7463
  • Format missed files: #​7464
  • Make react-ssr-prepeass external if not enabled: #​7466
  • Render valid optimized AMP by default: #​7465
  • Improve contributing doc without yarn link: #​7471
  • Revise dynamic route generation (mark 3): #​7473
  • Remove old optional dynamic <Link> test: #​7474
  • Do not leave Promise unresolved: #​7475
  • Reuse router logic instead of duping in client: #​7476
  • Add new stub file for exports: 7f187b4
  • Refresh query on mount for exported pages: #​7462
  • Consolidate import statements: f8e9cbb
  • Upgrade to latest typescript: #​7477
  • Remove .includes from _app for ie compatibility: #​7482
  • Update ant design examples: #​7490
  • Allow to describe initial props in the NextPage type: #​7491
  • Disable <title/> warning when React Helmet is used: #​7483
  • Fix serverDir resolving for autoExporting: #​7504
  • Fix create command - react-relay-network-modern: #​7502
  • Fix serverless dynamic routes: #​7505
  • API interface extensions: #​7363
  • Simplify a few parts of the codebase: #​7506
  • Fix autoExport on windows and add tests: #​7514
  • Fix auto export in serverless: #​7517
  • Replace recursive-copy with own implementation: #​7263
  • Clean up _document documentation: #​7523
  • Add types for &lt;Html&gt; and &lt;Head&gt; element: #​7524
  • Default target in loadConfig instead of next build: #​7521
  • Restore onMouseEnter event: #​7531
  • With-cookie-auth: don&#​39;t rely on the Host header: #​7435
  • Fixes constants link in readme: #​7534
  • TS: don&#​39;t set page component props to the App&#​39;s props by default: #​7535
  • Add Typescript to next-mdx readme: #​7540
  • Add export const config support and make withAmp a no-op: #​7525
  • Fix next start in serverless mode with public directory: #​7541
  • Fix sentence in with-context-api example: #​7542
  • Create file referencing Next.js types: #​7545
  • Don&#​39;t confuse the user with an eagerly created tsconfig.json: #​7546
  • Adding TypeScript description to next export: #​7547
  • Improve TypeScript package install experience: #​7548
  • Remove invalid meta type: #​7549
  • Add static page marker to page info: #​7552
  • Mark whether page is a lambda or static file in build output: #​7553
  • Tune default Terser configuration: #​7554
  • Strip queries before matching route on client: #​7566
  • Added new blog example: #​7511
  • Add handling for invalid pages during autoExport: #​7574
  • Improve docs: #​7564
  • Added nodemon config to watch for .ts and .js files in the server folder: #​7592
  • Re-require all module information for client-side initializers list: #​7571
  • Add next/dynamic test: #​7600
  • (examples/with-immutable-redux-wrapper) Fix README.md: #​7597
  • Ensure Node types are installed (for process types): #​7603
  • Correctly define NODE_ENV and process.browser: #​7604
  • typeof window will always be undefined on the server: #​7605
  • typeof window is object on the client: #​7606
  • Add error handling for _error page: #​7608
  • Exit process after build: #​7614
  • (example/with-react-relay-network-modern) Fix example: #​7590
  • Extract isDynamicRoute helper: #​7622
  • Dynamic Routes: Change impl from $param to [param]: #​7623
  • Set __next-build-watcher width and height to 0: #​7618
  • Fixes serverless target in development: #​7619
  • Update example: with redux reselect recompose: #​7624
  • Fix typo in with-redux-reselect-recompose example: #​7642
  • Revert "ncc Webpack build redux ": #​7628
  • _document middleware is experimental: #​7647
  • Compile dependencies for IE11: #​7646
  • Allow opting out of automatic prefetch for Link: #​7532
  • Fix TypeScript typings: #​7648
  • Avoid lambda nomenclature when target != &#&#8203;39;serverless&#&#8203;39;: #​7650
  • Remove usage of process.browser: #​7651
  • Update prefetch check to prevent re-prefetching: #​7654
  • Unflag Dynamic Routing: #​7663
  • Fix memory leak from requiring pages: #​7659
  • Parallelize requiring pages for static check: #​7671
  • Fix maxConcurrentCalls used instead of maxConcurrentWorkers: #​7672
  • Updating hapijs package name: #​7664
  • Asynchronously check for type errors: #​7668
  • Re-add require cache clearing: #​7674
  • Update typescript example: #​7684
  • Clean up AMP logic and naming: #​7669
  • Dynamic routes for API: #​7629
  • Helpers update: #​7686
  • Remove coveralls: #​7689
  • Expand automatic pre-rendering docs: #​7702
  • Improve prefetch docs: #​7692
  • Updated with-now-env example: #​7694
  • Add updated de-duping logic for next/dynamic: #​7705
  • Add path to exportPathMap query missing message: #​7708
  • Fix styled-jsx not rendering when used in node_modules: #​7697
  • Add back in second line of comment: #​7718
  • Remove "small" wording from runtime config overhead: #​7715
  • Upgrade watchpack to remove eslint-config-prettier: #​7716
  • Serverless build for API routes: #​7649
  • Remove Next.js debug mode: #​7719
  • Do not default TypeScript to strict: true: #​7717
  • Add prerender PageConfig option: #​7699
  • Update with-zones example and Multi Zones documentation: #​7513
Credits

Huge thanks to @​ijjk, @​Timer, @​andy-ob, @​koenpunt, @​TxHawks, @​mottox2, @​scull7, @​dav-is, @​Ephem, @​lfades, @​martpie, @​thecodechef, @​rarkins, @​chuck0523, @​sebastianbenz, @​stovmascript, @​nataliemarleny, @​nimit95, @​Tomekmularczyk, @​styfle, @​keanulee, @​coryshrmn, @​sync, @​huv1k, @​nabiltntn, @​aga5tya, @​Samciu, @​timneutkens, @​samw3, @​nguyenkhois, @​chibicode, @​AnsonT, @​jaydenseric, @​tajo, @​resir014, @​John-Spraul, @​delbaoliveira, @​guybedford, @​mrispoli24, @​leerob, @​stvnyung, @​tychay, @​jrusso1020, @​xboy2012, @​msheakoski, @​msweeneydev, @​icco, @​rafaelalmeidatk, @​keustma, @​mcwebb, @​Janpot, @​d-dmytro, @​ku8ar, @​olgn, @​lucleray, @​dunglas, @​abusada, @​AllenFang, @​j0lv3r4, @​jsmirandaiii, @​popenkomaksim, @​HsuTing, @​MarchWorks, @​khanghoang, @​eperedo, @​hanagejet, @​jchorl, and @​johnboy-leeds for helping!


Renovate configuration

📅 Schedule: At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

♻️ Rebasing: Whenever PR becomes conflicted, or if you modify the PR title to begin with "rebase!".

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Renovate Bot. View repository job log here.

@algobot
Copy link
Contributor

algobot commented Jul 8, 2019

Deploy preview for react-instantsearch ready!

Built with commit d7868b9

https://deploy-preview-2638--react-instantsearch.netlify.com

@samouss samouss merged commit d22f61d into master Jul 8, 2019
@samouss samouss deleted the renovate/major-nextjs-monorepo branch July 8, 2019 14:18
Haroenv added a commit that referenced this pull request Aug 21, 2019
# [6.0.0-beta.0](v5.7.0...v6.0.0-beta.0) (2019-08-21)

### Bug Fixes

* **compat:** upgrade Next.js example lifecycles ([#2379](#2379)) ([45939bc](45939bc))
* **compat:** upgrade RangeInput lifecycle ([#2289](#2289)) ([110b1af](110b1af))
* **compat:** upgrade RangeSlider lifecycle ([#2290](#2290)) ([69a7f53](69a7f53))
* **compat:** upgrade React Native example and its lifecycles ([#2304](#2304)) ([f390c17](f390c17))
* **compat:** upgrade React Router example lifecycles ([#2307](#2307)) ([ab828b0](ab828b0))
* **compat:** upgrade React Router v3 example lifecycles ([#2314](#2314)) ([3647154](3647154))
* **compat:** upgrade SearchBox lifecycle ([#2288](#2288)) ([c3ba42d](c3ba42d))
* **compat:** upgrade Tourism example lifecycles ([#2305](#2305)) ([fff5aa6](fff5aa6))
* **connectToggleRefinement:** cast currentRefinement to boolean ([#2701](#2701)) ([db934fd](db934fd))
* **core:** searchState can be non-Object object ([#2722](#2722)) ([dea493c](dea493c)), closes [#2568](#2568)
* **createConnector:** new life cycles ([#2357](#2357)) ([fc10640](fc10640))
* **createInstantSearchManager:** do not trigger search on index update ([#2552](#2552)) ([e209362](e209362))
* **deps:** update dependency antd to v3.19.3 ([#2530](#2530)) ([73636c5](73636c5))
* **deps:** update dependency antd to v3.19.4 ([#2559](#2559)) ([c3e8267](c3e8267))
* **deps:** update dependency antd to v3.19.5 ([#2560](#2560)) ([72efd31](72efd31))
* **deps:** update dependency antd to v3.19.6 ([#2564](#2564)) ([654f986](654f986))
* **deps:** update dependency antd to v3.19.7 ([#2573](#2573)) ([7e963ad](7e963ad))
* **deps:** update dependency antd to v3.19.8 ([#2584](#2584)) ([34dd9b2](34dd9b2))
* **deps:** update dependency antd to v3.20.0 ([#2611](#2611)) ([b976c67](b976c67))
* **deps:** update dependency antd to v3.20.1 ([#2635](#2635)) ([792ad9c](792ad9c))
* **deps:** update dependency antd to v3.20.2 ([#2655](#2655)) ([301c2d8](301c2d8))
* **deps:** update dependency antd to v3.20.3 ([#2658](#2658)) ([d078e70](d078e70))
* **deps:** update dependency antd to v3.20.5 ([#2686](#2686)) ([42ef821](42ef821))
* **deps:** update dependency antd to v3.20.6 ([#2711](#2711)) ([927fbfe](927fbfe))
* **deps:** update dependency antd to v3.20.7 ([#2712](#2712)) ([1830952](1830952))
* **deps:** update dependency antd to v3.21.1 ([#2736](#2736)) ([39a51a6](39a51a6))
* **deps:** update dependency antd to v3.21.2 ([#2738](#2738)) ([a7a998a](a7a998a))
* **deps:** update dependency antd to v3.21.4 ([#2747](#2747)) ([60012be](60012be))
* **deps:** update dependency antd to v3.22.0 ([#2758](#2758)) ([9cda468](9cda468))
* **deps:** update dependency lodash to v4.17.13 ([c4974cf](c4974cf))
* **deps:** update dependency lodash to v4.17.14 ([#2647](#2647)) ([a2d2dd5](a2d2dd5))
* **deps:** update dependency lodash to v4.17.15 ([#2684](#2684)) ([354143f](354143f))
* **deps:** update dependency next to v9 ([#2638](#2638)) ([d22f61d](d22f61d))
* **deps:** update dependency next to v9.0.1 ([#2652](#2652)) ([2c2dab9](2c2dab9))
* **deps:** update dependency next to v9.0.2 ([#2662](#2662)) ([6fa4c5e](6fa4c5e))
* **deps:** update dependency next to v9.0.3 ([#2724](#2724)) ([f51b04b](f51b04b))
* **deps:** update dependency next to v9.0.4 ([#2767](#2767)) ([9af9180](9af9180))
* **deps:** update dependency qs to v6.8.0 ([#2757](#2757)) ([8bffb87](8bffb87))
* **deps:** update dependency react-compound-slider to v2.1.0 ([#2610](#2610)) ([3389ee5](3389ee5))
* **deps:** update dependency react-compound-slider to v2.2.0 ([#2649](#2649)) ([7b81af1](7b81af1))
* **deps:** update dependency react-native-vector-icons to v6.5.0 ([#2520](#2520)) ([5f7f5b6](5f7f5b6))
* **deps:** update dependency react-native-vector-icons to v6.6.0 ([#2599](#2599)) ([b6bb199](b6bb199))
* **deps:** update dependency react-router-dom to v5.0.1 ([#2506](#2506)) ([d762230](d762230))
* **geo:** check for undefined in isEqual ([#2643](#2643)) ([a544231](a544231)), closes [#2467](#2467)
* **geo:** remove lifecycle compat ([#2644](#2644)) ([2b2b898](2b2b898)), closes [#2626](#2626)
* **highlight:** switch to index as key ([#2690](#2690)) ([51de682](51de682))
* **highlight:** switch to index as key ([#2691](#2691)) ([17e75d1](17e75d1)), closes [#2688](#2688)
* **peerDependencies:** update React ([#2626](#2626)) ([6ccad49](6ccad49))
* **ssr:** avoid duplicate serializing ([#2726](#2726)) ([c768b1a](c768b1a))
* **voiceSearch:** fix incorrect status on stop ([#2535](#2535)) ([824dc22](824dc22))

### Code Refactoring

* **lodash:** get ([#2461](#2461)) ([527b879](527b879))
* **lodash:** has ([#2434](#2434)) ([75a4a15](75a4a15))

### Features

* **autocomplete:** add queryID & position to provided hits ([#2687](#2687)) ([e453dab](e453dab))
* **client:** remove algoliaClient, appId & apiKey ([#2338](#2338)) ([b84a0b5](b84a0b5))
* **context:** migrate to new React context ([#2178](#2178)) ([0a1abea](0a1abea)), closes [#2179](#2179) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2189](#2189) [#2190](#2190) [#2179](#2179) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2190](#2190)
* **ssr:** update the SSR API ([#2555](#2555)) ([925bdb8](925bdb8)), closes [#2536](#2536) [#2537](#2537)

### BREAKING CHANGES

* **lodash:** no longer do we allow paths like `attribute[5].something`, or other indexed forms, only `.` is allowed as special key.

All existing tests still pass, and we never documented you could use `lodash.get` patterns other than `.`.

* feat(get): accept array & bracked-separated string

moved to utils at the same time

* fix typo

* feedback: test for undefined behaviour

* chore(size): update expectation

this will go down afterwards, but for now there's some more duplication
* **lodash:** translation will render default value if passed undefined as value

* chore(lodash): remove imports

* fix(translation): allow undefined value to be passed on purpose
tkrugg added a commit that referenced this pull request Oct 18, 2019
* refactor(DOMMaps): use new React Context API (#2023)

* fix(maps): migrate to new React Context API

* refactor(maps): update context props to TypeScript

* refactor(maps): rename context types

* fix(maps): provide default context values

* fix(maps): remove `displayName`s

* test(maps): remove getStateContext function uses

* fix(maps): use React ref API

* fix(maps): update context usage

- Pass state from provider
- Pass context as props to children

* test(maps): implement Connected tests

* style(maps): lint files

* test(maps): test withGoogleMaps

* test(maps): update GoogleMaps tests

* fix(maps): set the state only once

* fix(maps): add ref to map element

* fix(maps): use static field for state

* test(maps): inline props in test

* fix(maps): use class field in Provider

* fix(maps): render provider when map is ready

* fix(maps): memoize values passed to context in Provider

* test(maps): test GoogleMaps context

* fix(maps): return undefined in GeoSearchContext

* revert: fix(maps): return undefined in GeoSearchContext

This reverts commit 3733602.

* chore(tslint): disable no-empty rule

* test(maps): inline props in Redo test

* fix(maps): apply changes

* fix(maps): cast default GoogleMapsContext values

* test(maps): test Provider mapValue reference

* fix(maps): add comment on GoogleMapsContext

* test(maps): update GoogleMaps tests

* feat(context): migrate to new React context (#2178)

This PR is quite long, but is split up in these steps

- [x] **STEP 1**: migrate createConnector (#2178, this PR)
- [x] **STEP 2**: first PR with connectors (searchbox, configure, hits, pagination) (#2179)
- [x] **STEP 3**: other connectors (#2180)
- [x] **STEP 4**: Multi index core (#2181)
- [x] **STEP 5**: Multi index connectors (#2185)
- [x] **STEP 6**: SSR (#2192)
- [ ] **STEP 7**: TypeScript completion (#2189) (merged later)
- [x] **STEP 8**: documentation change (#2190)

* feat(context): migrate core [STEP 1]

This includes:

1. change to createConnector
2. change to createStore
3. skip failing tests
4. small nits found while coding

After this to do:

STEP 2: first PR with connectors (searchbox, configure, hits, pagination)
STEP 3+: other connectors
STEP 4: Multi index core
STEP 5+: Multi index connectors
STEP 6: SSR
STEP 7: TypeScript completion
STEP 8: documentation change

* chore: remove context cache

* chore(tslint): add back accidentally removed prettier

* fix(connector): call gPP with correct "this"

* chore(TS): ReactType for Root

* test(connector): swap mount for shallow where possible

* chore(InstantSearch): refactor branch

* test(InstantSearch): avoid mutation

* chore(connector): remove unused

* chore(createConnector): warn on creation instead of mount

* fix(connector): remove unused variable

* chore(connector): consistent if

* chore(store): simplify typing

* chore(stories): better display name

* chore(TS): fix typing of results

* chore: remove useless comments

* consistent naming

* fix(InstantSearch): update index name when it changes

* prettier

* chore: remove old comment

* chore: fix merge

* ci: remove no-empty rule

* fix: make TS work in new connectors

* chore: fix bundlesize

* feedback from review (remove comments & warning)

* more review comments

* Update packages/react-instantsearch-core/src/components/InstantSearch.tsx

Co-Authored-By: Haroenv <fingebimus@me.com>

* feat(context): migrate base connector [STEP 2] (#2179)

* feat(context): migrate core [STEP 1]

This includes:

1. change to createConnector
2. change to createStore
3. skip failing tests
4. small nits found while coding

After this to do:

STEP 2: first PR with connectors (searchbox, configure, hits, pagination)
STEP 3+: other connectors
STEP 4: Multi index core
STEP 5+: Multi index connectors
STEP 6: SSR
STEP 7: TypeScript completion
STEP 8: documentation change

* feat(context): migrate base connector [STEP 2]

This is enough changes to be able to look at the storybook without errors again (only pagination, hits, searchbox of course, and nothing multi-index)

For full roadmap, see #2178

* test(configure): test with non-global this

* chore: from merge

* chore: updat bundle size

* chore: remove stuff from bad merge

* feedback from review

* feat(context): migrate remaining connectors [STEP 3] (#2180)

* feat(context): migrate remaining connectors [STEP 3]

chore: remove wrong import

test(currentRefinements): remove unused context

chore(range): fix typo

fix(geoSearch): gSP

test: call connectors with unique context where possible

feedback from review

chore(infiniteHits): cleaner test

refactor: migrate new connectors

chore: prettier

fix context

default props

fix TS

chore: small fix

* feat(context): multi-index [STEP 4] (#2181)

* feat(context): migrate remaining connectors [STEP 3]

* chore: remove wrong import

* test(currentRefinements): remove unused context

* chore(range): fix typo

* fix(geoSearch): gSP

* test: call connectors with unique context where possible

* feedback from review

* chore(infiniteHits): cleaner test

* refactor: migrate new connectors

* chore: prettier

* fix context

* default props

* fix TS

* chore: small fix

* feat(context): multi-index [STEP 4]

  test(Index): re-enable and make work

  fix(Index): allow context to be empty initially

  fix(Index): onSearchParameters with correct context

  fix(connector): onSearchParameters with correct context

  chore(Index): remove else

  chore(Index): consistent integration test

  chore: clarify test

  chore: fix life cycle

  fix(ts): index context can be undefined

  feedback from review

  fix(index): correct life cycles

  fix TS on Index

  connectorWrapper

  chore: update snapshots

* feat(context): apply multi-index [STEP 5] (#2185)

Co-Authored-By: samouss <samouss@users.noreply.github.com>

  * feat(context): modify Index to use modern context

  * test(Index): re-enable and make work

  * fix(Index): allow context to be empty initially

  * fix(Index): onSearchParameters with correct context

  * fix(connector): onSearchParameters with correct context

  * chore(Index): remove else

  * chore(Index): consistent integration test

  * chore: clarify test

  * chore: fix life cycle

  * fix(ts): index context can be undefined

  * feedback from review

  * fix(index): correct life cycles

  * fix TS on Index

  * connectorWrapper

  * chore: update snapshots

  * feat(context): modify Index to use modern context

  * feat(context): apply multi-index [STEP 5]

  1. connectMenu

  * connectAutoComplete

  * connectBreadcrumb

  * connectConfigure

  * connectGeoSearch

  * connectHierarchicalMenu

  * connectHits

  * connectHitsPerPage

  * connectInfiniteHits

  * connectNumericMenu

  * connectPagination

  * connectStats

  * connectRange

  * connectRefinementList

  * connectScrollTo

  * connectSearchBox

  * test(hierarchical): remove shadowing

  * connectSortBy

  * connectStateResults

  * connectToggleRefinement

  * fix(configure): use multi-index context

  * chore(configure): replace lodash.omit by spreading

  * test(connectors): call changing context

  * chore(configure): less lodash

  * test(configure): more detailed test

  * chore(test): rename ctx to instance

  * chore: move test

  * suggestions from review (mainly making multi-index tests more interesting)

  * chore: fix bundlesize

  * wrong conflict

  * migrate connectQueryRules

  * Feedback from review

  * fix(hitInsights): re-enable multi-index tests

* feat(context): re-enable SSR [STEP 6] (#2192)

  * chore(ssr): unskip tests

  * test(ssr): better test implem

  * chore: remove unused file

  * test: more consistent mock

* docs(connectors): fix spelling [STEP 8] (#2190)

  These are misc fixes in spelling that didn't exactly fit in a different PR

  remove small typo

* chore(context): migrate Panel (#2203)

* chore(context): migrate Panel

This migration is fairly straightforward, and has no impact on how the PanelCallbackHandler is used, although it adds a new component in that tree so it can read the context

IFW-485

* refactor(lodash): pick (#2432)

* refactor(lodash): pick

replaced by destructuring

* chore: remove isEmpty variable

* chore(utils): rename to TS

* chore(TS): rename dom utils

* chore(TS): add minor types to dom utils

* chore(TS): ignore lint rule

* refactor(lodash): range (#2444)

IFW-739

* fix(createConnector): new life cycles (#2357)

* fix(createConnector): new life cycles

- move willMount -> constructor
- move willReceiveProps -> didUpdate

This didn't have an impact on more requests, but did cause one more render if you update a prop

IFW-671

* remove comment

* test(sCU): shouldComponentUpdate is called two separate times now

* refactor(lodash): remove fill (#2454)

I replaced this by the `range` utility merged earlier, since it's basically what was needed here.

IFW-741

* refactor(lodash): remove difference (#2455)

Both are arrays & always defined, so it's really enough to find all props in this._props (prevProps), but not in `props`

* refactor(lodash): remove zipWith (#2459)

* refactor(lodash): remove zipWith

IFW-737

* chore: add comment back

* refactor(lodash): replace isFinite (#2458)

* refactor(lodash): replace isFinite

lodash.isFinite is just `typeof value == 'number' && nativeIsFinite(value);`, so that's what I implemented

IFW-745

* chore: remove needless typeof

* refactor(lodash): isPlainObject (#2460)

* refactor(lodash): isPlainObject

The values this function was used for seemed like they can only be arrays or objects to me.

We will only want to empty out "breadth-first", so empty objects will stay in the output if they became empty because of the function itself.

isEmpty here is removed in #2442, and still works the same (but will need a rebase)

The newly added tests also pass with the previous implementation

The function is only used in `onSearchStateChange` as a response to a `cleanUp` (caused by unmount) on a widget

IFW-743

* test: remove only

* chore(ts): use `unknown`

* refactor(lodash): replace find (#2446)

Chosen to duplicate the funciton in core & dom, because we have no good way to share functionality otherwise

IFW-740

* refactor(lodash): has (#2434)

* refactor(lodash): has

replace mostly by item[key] === undefined, which isn't completely the same, but close enough in our case, since rendering undefined would be quite weird.

BREAKING CHANGE:
translation will render default value if passed undefined as value

* chore(lodash): remove imports

* fix(translation): allow undefined value to be passed on purpose

*  refactor(lodash): replace isEqual (#2467)

* refactor(lodash): replace isEqual

1. specified function for maps

IFW-735

* refactor(lodash): replace isEqual with fast-deep-equal

* refactor(lodash): replace omit (#2466)

* refactor(lodash): omit (dom)

In this case, you can simply override a prop, which will take preference, like in any other object.

* refactor(omit): use internal (babel) replacement

* refactor(omit): use destructuring replacement

* refactor(indexUtils): use new omit where possible

* refactor(indexutils): remove omit with path

* chore: fix merge

* chore(size): update

* chore(life cycle): add comments where change is necessary

* fix(compat): upgrade SearchBox lifecycle (#2288)

* fix(compat): upgrade RangeSlider lifecycle (#2290)

* fix(compat): upgrade RangeInput lifecycle (#2289)

* fix(compat): upgrade Tourism example lifecycles (#2305)

* feat(client): remove algoliaClient, appId & apiKey (#2338)

* feat(client): remove algoliaClient alias

* chore(error): remove duplicate colon

* docs(examples): use searchClient everywhere

* feat(searchClient): remove other options

* adds back user agent tests & remove defaultAlgoliaClient

* remove algoliasearch from dependencies

* remove algoliasearch usage

* chore: update max size

* fix(propTypes): more strict searchClient type

* chore(examples): add algoliasearch as dependency

* chore(stories): memoize search client

* chore: update proptype

* refactor(lodash): get (#2461)

* refactor(lodash): get

IFW-742

BREAKING CHANGE: no longer do we allow paths like `attribute[5].something`, or other indexed forms, only `.` is allowed as special key.

All existing tests still pass, and we never documented you could use `lodash.get` patterns other than `.`.

* feat(get): accept array & bracked-separated string

moved to utils at the same time

* fix typo

* feedback: test for undefined behaviour

* chore(size): update expectation

this will go down afterwards, but for now there's some more duplication

* refactor(lodash): isEmpty (#2442)

* refactor(lodash): isEmpty

reusing objectHasKeys strategy from the helper

IFW-736

* refactor(lodash): remove isEmpty from server

* chore(TS): clearer type

* feedback: don't use objectHasKeys for array

* fix implementation

* refactor(example): remove lodash

* fix(numeric): correct reimplementation of !isEmpty

* chore(size): update expectation

somewhat bigger for now, but in the long run it'll shrink

* fix(compat): upgrade React Router example lifecycles (#2307)

* fix(compat): upgrade React Router v3 example lifecycles (#2314)

* fix(compat): upgrade React Native example and its lifecycles (#2304)

* fix(compat): upgrade Next.js example lifecycles (#2379)

* fix(compat): update Next example

* fix(compat): use last Next router

* fix(createInstantSearchManager): do not trigger search on index update (#2552)

* fix(createInstantSearchManager): do not trigger search on index update

* fix(createInstantSearchManager): add comment in updateIndex

* feat(ssr): update the SSR API (#2555)

* feat(ssr): only expose findResultsState [PART-1] (#2536)

* feat(ssr): hydrate client [PART-2] (#2537)

* feat(ssr): update usage of the API [PART-3]

* refactor(root): remove createIndex & createInstantSearch (#2339)

* refactor(InstantSearch): migrate life cycles (#2349)

*  fix(createInstantSearchManager): fix multi-index search  (#2570)

* fix(createInstantSearchManager): fix multi-index search

* Fix tests

* Update bundlesize

* Map indexName prop to indexId when indexId is not defined

* Add tests

* Pass indexName through variable for clarity

* Simplify test

* Simplify other tests

* refactor(lodash): orderBy (#2462)

* refactor(lodash): orderBy

The utility is copied from the helper (which passed all lodash tests), I put it inline in the connector, since it's not used in any other spot.

IFW-746

* refactor(menu): remove orderBy & use helper method

These tests provide no security at all, but this change in behaviour can be confirmed in the stories.

* chore(indexUtils): make usage simpler

I caught this when trying to refactor the tests to use a real helper, but eventually decided not to do that

* chore: update test name

* chore: different if style

* chore(test): simplify

* chore: update sizes

* chore(size): looser limit

* simplify code

* chore: update bundlesize

* chore(lint): remove wrong merges

* chore(react-native): roll back react version

* chore(lint): small fix

* chore(ssr): fix example build

* chore(lodash): remove dependencies (#2600)

- lodash from packages
- babel-plugin-lodash from root
- swap out isEqual from connectInfiniteHits

IFW-778

closes #2468

* fix(peerDependencies): update React (#2626)

* fix(peerDependencies): update React

We are now relying on React 16.3 features like `static getDerivedStateFromProps` in the library, which thus won't work with lower versions.

The lowest version of React Native which requires React 16.3 (albeit an alpha) is 0.54.0.

* !fixup

* refactor(helper): replace Helper usage (#2621)

* docs(MIGRATION): migrate to v6 (#2627)

* docs(MIGRATION): migrate to v6

* docs(MIGRATION): update wording

Co-Authored-By: Haroen Viaene <fingebimus@me.com>
Co-Authored-By: François Chalifour <francoischalifour@users.noreply.github.com>

* docs(MIGRATION): add snippet for appID & apiKey

* docs(MIGRATION): add algoliasearchHelper section

* fix(geo): remove lifecycle compat (#2644)

This is no longer necessary, since we now require React 16.3 as a peer dependency (#2626)

* docs(stories): remove stories whoich highlight a custom root (#2645)

This has been removed in #2339, so no longer works (nor necessary)

* fix(geo): check for undefined in isEqual (#2643)

issue introduced in #2467

IFW-851

* fix(highlight): switch to index as key (#2690)

the reason is that the full value could be duplicate, so we added the index; but the index can't be duplicate within the list.

* feat(autocomplete): add queryID & position to provided hits (#2687)

* feat(autocomplete): add queryID to provided hits if defined

This was accidentally forgotten when we added the queryID to hits & infinite hits.

IFW-902

* feat(autocomplete): add absolute position too

* Update packages/react-instantsearch-core/src/connectors/__tests__/connectAutoComplete.js

* fix(core): searchState can be non-Object object (#2722)

* fix(core): searchState can be non-Object object

If someone calls `Object.create(null)` and then adds the expected properties, `hasOwnProperty` will not be available on the object itself. 

fixes #2568

* fix(ssr): avoid duplicate serializing (#2726)

* fix(ssr): avoid duplicate serializing

Response of `findResultsState` (and `resultsState` prop) before:

```js
const resultsState = {
  content: SearchResults(state: searchParameters, results: rawResults),
  state: searchParameters,
  _originalResponse: {
    results: rawResults
  },
};
```

Note that `SearchResults` has the properties `_rawResults` & `_state`. This means that when we serialize, we are retrieving the original response and state twice.

Then on further searching, I also find that we don't need to serialize the `SearchResults` object at all, since only the raw response and state is used.

I modified this to be more consistent and no longer have duplication:

```js
const resultsState = {
  state: searchParameters,
  rawResults,
};
```

The `SearchParameters` object gets serialized without issue, as before.

This change in shape has of course also an impact on the shape of `resultsState`, the prop, but that is fine, since it was previously typed as `any`.

To be able to type it correctly, I had to add `@types/algoliasearch` & update `algoliasearch-helper` for typescript though.

This was initially noticed by @cloakedninjas, thanks!

* empty commit for CI

* chore: fix linting for next

* chore: fix lint again 🤔

* chore(examples): downgrade react in rn example

* v6.0.0-beta.0

# [6.0.0-beta.0](v5.7.0...v6.0.0-beta.0) (2019-08-21)

### Bug Fixes

* **compat:** upgrade Next.js example lifecycles ([#2379](#2379)) ([45939bc](45939bc))
* **compat:** upgrade RangeInput lifecycle ([#2289](#2289)) ([110b1af](110b1af))
* **compat:** upgrade RangeSlider lifecycle ([#2290](#2290)) ([69a7f53](69a7f53))
* **compat:** upgrade React Native example and its lifecycles ([#2304](#2304)) ([f390c17](f390c17))
* **compat:** upgrade React Router example lifecycles ([#2307](#2307)) ([ab828b0](ab828b0))
* **compat:** upgrade React Router v3 example lifecycles ([#2314](#2314)) ([3647154](3647154))
* **compat:** upgrade SearchBox lifecycle ([#2288](#2288)) ([c3ba42d](c3ba42d))
* **compat:** upgrade Tourism example lifecycles ([#2305](#2305)) ([fff5aa6](fff5aa6))
* **connectToggleRefinement:** cast currentRefinement to boolean ([#2701](#2701)) ([db934fd](db934fd))
* **core:** searchState can be non-Object object ([#2722](#2722)) ([dea493c](dea493c)), closes [#2568](#2568)
* **createConnector:** new life cycles ([#2357](#2357)) ([fc10640](fc10640))
* **createInstantSearchManager:** do not trigger search on index update ([#2552](#2552)) ([e209362](e209362))
* **deps:** update dependency antd to v3.19.3 ([#2530](#2530)) ([73636c5](73636c5))
* **deps:** update dependency antd to v3.19.4 ([#2559](#2559)) ([c3e8267](c3e8267))
* **deps:** update dependency antd to v3.19.5 ([#2560](#2560)) ([72efd31](72efd31))
* **deps:** update dependency antd to v3.19.6 ([#2564](#2564)) ([654f986](654f986))
* **deps:** update dependency antd to v3.19.7 ([#2573](#2573)) ([7e963ad](7e963ad))
* **deps:** update dependency antd to v3.19.8 ([#2584](#2584)) ([34dd9b2](34dd9b2))
* **deps:** update dependency antd to v3.20.0 ([#2611](#2611)) ([b976c67](b976c67))
* **deps:** update dependency antd to v3.20.1 ([#2635](#2635)) ([792ad9c](792ad9c))
* **deps:** update dependency antd to v3.20.2 ([#2655](#2655)) ([301c2d8](301c2d8))
* **deps:** update dependency antd to v3.20.3 ([#2658](#2658)) ([d078e70](d078e70))
* **deps:** update dependency antd to v3.20.5 ([#2686](#2686)) ([42ef821](42ef821))
* **deps:** update dependency antd to v3.20.6 ([#2711](#2711)) ([927fbfe](927fbfe))
* **deps:** update dependency antd to v3.20.7 ([#2712](#2712)) ([1830952](1830952))
* **deps:** update dependency antd to v3.21.1 ([#2736](#2736)) ([39a51a6](39a51a6))
* **deps:** update dependency antd to v3.21.2 ([#2738](#2738)) ([a7a998a](a7a998a))
* **deps:** update dependency antd to v3.21.4 ([#2747](#2747)) ([60012be](60012be))
* **deps:** update dependency antd to v3.22.0 ([#2758](#2758)) ([9cda468](9cda468))
* **deps:** update dependency lodash to v4.17.13 ([c4974cf](c4974cf))
* **deps:** update dependency lodash to v4.17.14 ([#2647](#2647)) ([a2d2dd5](a2d2dd5))
* **deps:** update dependency lodash to v4.17.15 ([#2684](#2684)) ([354143f](354143f))
* **deps:** update dependency next to v9 ([#2638](#2638)) ([d22f61d](d22f61d))
* **deps:** update dependency next to v9.0.1 ([#2652](#2652)) ([2c2dab9](2c2dab9))
* **deps:** update dependency next to v9.0.2 ([#2662](#2662)) ([6fa4c5e](6fa4c5e))
* **deps:** update dependency next to v9.0.3 ([#2724](#2724)) ([f51b04b](f51b04b))
* **deps:** update dependency next to v9.0.4 ([#2767](#2767)) ([9af9180](9af9180))
* **deps:** update dependency qs to v6.8.0 ([#2757](#2757)) ([8bffb87](8bffb87))
* **deps:** update dependency react-compound-slider to v2.1.0 ([#2610](#2610)) ([3389ee5](3389ee5))
* **deps:** update dependency react-compound-slider to v2.2.0 ([#2649](#2649)) ([7b81af1](7b81af1))
* **deps:** update dependency react-native-vector-icons to v6.5.0 ([#2520](#2520)) ([5f7f5b6](5f7f5b6))
* **deps:** update dependency react-native-vector-icons to v6.6.0 ([#2599](#2599)) ([b6bb199](b6bb199))
* **deps:** update dependency react-router-dom to v5.0.1 ([#2506](#2506)) ([d762230](d762230))
* **geo:** check for undefined in isEqual ([#2643](#2643)) ([a544231](a544231)), closes [#2467](#2467)
* **geo:** remove lifecycle compat ([#2644](#2644)) ([2b2b898](2b2b898)), closes [#2626](#2626)
* **highlight:** switch to index as key ([#2690](#2690)) ([51de682](51de682))
* **highlight:** switch to index as key ([#2691](#2691)) ([17e75d1](17e75d1)), closes [#2688](#2688)
* **peerDependencies:** update React ([#2626](#2626)) ([6ccad49](6ccad49))
* **ssr:** avoid duplicate serializing ([#2726](#2726)) ([c768b1a](c768b1a))
* **voiceSearch:** fix incorrect status on stop ([#2535](#2535)) ([824dc22](824dc22))

### Code Refactoring

* **lodash:** get ([#2461](#2461)) ([527b879](527b879))
* **lodash:** has ([#2434](#2434)) ([75a4a15](75a4a15))

### Features

* **autocomplete:** add queryID & position to provided hits ([#2687](#2687)) ([e453dab](e453dab))
* **client:** remove algoliaClient, appId & apiKey ([#2338](#2338)) ([b84a0b5](b84a0b5))
* **context:** migrate to new React context ([#2178](#2178)) ([0a1abea](0a1abea)), closes [#2179](#2179) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2189](#2189) [#2190](#2190) [#2179](#2179) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2190](#2190)
* **ssr:** update the SSR API ([#2555](#2555)) ([925bdb8](925bdb8)), closes [#2536](#2536) [#2537](#2537)

### BREAKING CHANGES

* **lodash:** no longer do we allow paths like `attribute[5].something`, or other indexed forms, only `.` is allowed as special key.

All existing tests still pass, and we never documented you could use `lodash.get` patterns other than `.`.

* feat(get): accept array & bracked-separated string

moved to utils at the same time

* fix typo

* feedback: test for undefined behaviour

* chore(size): update expectation

this will go down afterwards, but for now there's some more duplication
* **lodash:** translation will render default value if passed undefined as value

* chore(lodash): remove imports

* fix(translation): allow undefined value to be passed on purpose

* chore(deps): update examples to react-instantsearch v6.0.0-beta.0

* chore(index): don't require `indexId` on `IndexWrapper` (#2834)

* Don't require `indexId` proptype on Index widget wrapper

* Use unique type for IndexWrapper props

* merge branch master into next

* test(examples): update snapshots (#2845)

* fix(ssr): add error when no indexName is passed (#2842)

* fix(InstantSearch): update the searchState on props update (#2852)

**Summary**

This PR fixes an issue where an infinite loop occurs with the controlled mode. The update of the `searchState` was done too late. With V5 the update was done inside `cWRP` but with V6 we move the update inside `cDU`. This change has an impact on when the `searchState` is updated. With `cWRP` it was executed before the `render` of the children, it's not the case anymore with `cDU`. It's done after.

Those children can read the `searchState` provided by the manager. When it's not up to date they alter the previous version of the state. With an `onSearchStateChange` function that relies on the value of `searchState` to add remove parameters, it can lead to infinite loop because the props are changes/reverted at each render.

The fix uses `getDerivedStateFromProps` to keep the `searchState` up to date. The issue with this solution (on V5 too) is that we might trigger one useless request when the props change. It's because the update and the search are tied together inside `onExternalStateUpdate`. One solution to this would be to decouple the two. Apply the `searchState` update as soon as possible but trigger the search on `cDU` once we've computed the state from the children.

**Before**

![before](https://user-images.githubusercontent.com/6513513/66131368-9c15d180-e5f3-11e9-9aad-c46ea6fca340.gif)

**After**

![after](https://user-images.githubusercontent.com/6513513/66131378-9f10c200-e5f3-11e9-8980-e6a6e5d626a4.gif)

* refactor(example): remove usage of aroundLatLng (#2853)

**Summary**

This PR removes the usage of `aroundLatLng` inside the geo-search example. The logic to apply the parameter was present, but the App doesn't expose a way to use it. We don't have to support it since it uses either the IP of the user of the bounding box of the map.
tkrugg added a commit that referenced this pull request Oct 18, 2019
# [6.0.0-beta.1](v5.7.0...v6.0.0-beta.1) (2019-10-18)

### Bug Fixes

* **connectToggleRefinement:** cast currentRefinement to boolean ([#2701](#2701)) ([db934fd](db934fd))
* **deps:** update dependency antd to v3.19.3 ([#2530](#2530)) ([73636c5](73636c5))
* **deps:** update dependency antd to v3.19.4 ([#2559](#2559)) ([c3e8267](c3e8267))
* **deps:** update dependency antd to v3.19.5 ([#2560](#2560)) ([72efd31](72efd31))
* **deps:** update dependency antd to v3.19.6 ([#2564](#2564)) ([654f986](654f986))
* **deps:** update dependency antd to v3.19.7 ([#2573](#2573)) ([7e963ad](7e963ad))
* **deps:** update dependency antd to v3.19.8 ([#2584](#2584)) ([34dd9b2](34dd9b2))
* **deps:** update dependency antd to v3.20.0 ([#2611](#2611)) ([b976c67](b976c67))
* **deps:** update dependency antd to v3.20.1 ([#2635](#2635)) ([792ad9c](792ad9c))
* **deps:** update dependency antd to v3.20.2 ([#2655](#2655)) ([301c2d8](301c2d8))
* **deps:** update dependency antd to v3.20.3 ([#2658](#2658)) ([d078e70](d078e70))
* **deps:** update dependency antd to v3.20.5 ([#2686](#2686)) ([42ef821](42ef821))
* **deps:** update dependency antd to v3.20.6 ([#2711](#2711)) ([927fbfe](927fbfe))
* **deps:** update dependency antd to v3.20.7 ([#2712](#2712)) ([1830952](1830952))
* **deps:** update dependency antd to v3.21.1 ([#2736](#2736)) ([39a51a6](39a51a6))
* **deps:** update dependency antd to v3.21.2 ([#2738](#2738)) ([a7a998a](a7a998a))
* **deps:** update dependency antd to v3.21.4 ([#2747](#2747)) ([60012be](60012be))
* **deps:** update dependency antd to v3.22.0 ([#2758](#2758)) ([9cda468](9cda468))
* **deps:** update dependency antd to v3.22.2 ([#2791](#2791)) ([ff1f5d9](ff1f5d9))
* **deps:** update dependency antd to v3.23.2 ([#2814](#2814)) ([a190410](a190410))
* **deps:** update dependency lodash to v4.17.13 ([c4974cf](c4974cf))
* **deps:** update dependency lodash to v4.17.14 ([#2647](#2647)) ([a2d2dd5](a2d2dd5))
* **deps:** update dependency lodash to v4.17.15 ([#2684](#2684)) ([354143f](354143f))
* **deps:** update dependency next to v9 ([#2638](#2638)) ([d22f61d](d22f61d))
* **deps:** update dependency next to v9.0.1 ([#2652](#2652)) ([2c2dab9](2c2dab9))
* **deps:** update dependency next to v9.0.2 ([#2662](#2662)) ([6fa4c5e](6fa4c5e))
* **deps:** update dependency next to v9.0.3 ([#2724](#2724)) ([f51b04b](f51b04b))
* **deps:** update dependency next to v9.0.4 ([#2767](#2767)) ([9af9180](9af9180))
* **deps:** update dependency next to v9.0.5 ([#2789](#2789)) ([0a75f41](0a75f41))
* **deps:** update dependency qs to v6.8.0 ([#2757](#2757)) ([8bffb87](8bffb87))
* **deps:** update dependency react-compound-slider to v2.1.0 ([#2610](#2610)) ([3389ee5](3389ee5))
* **deps:** update dependency react-compound-slider to v2.2.0 ([#2649](#2649)) ([7b81af1](7b81af1))
* **deps:** update dependency react-native-vector-icons to v6.5.0 ([#2520](#2520)) ([5f7f5b6](5f7f5b6))
* **deps:** update dependency react-native-vector-icons to v6.6.0 ([#2599](#2599)) ([b6bb199](b6bb199))
* **deps:** update dependency react-router-dom to v5.0.1 ([#2506](#2506)) ([d762230](d762230))
* **highlight:** switch to index as key ([#2691](#2691)) ([17e75d1](17e75d1)), closes [#2688](#2688)
* **voiceSearch:** fix incorrect status on stop ([#2535](#2535)) ([824dc22](824dc22))

### chore

* **release:** 6.0.0-beta.1 ([#2861](#2861)) ([cb56ca0](cb56ca0)), closes [#2023](#2023) [#2178](#2178) [#2178](#2178) [#2179](#2179) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2189](#2189) [#2190](#2190) [#2179](#2179) [#2178](#2178) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2190](#2190) [#2203](#2203) [#2432](#2432) [#2444](#2444) [#2357](#2357) [#2454](#2454) [#2455](#2455) [#2459](#2459) [#2458](#2458) [#2460](#2460) [#2442](#2442) [#2446](#2446) [#2434](#2434) [#2467](#2467) [#2466](#2466) [#2288](#2288) [#2290](#2290) [#2289](#2289) [#2305](#2305) [#2338](#2338) [#2461](#2461) [#2442](#2442) [#2307](#2307) [#2314](#2314) [#2304](#2304) [#2379](#2379) [#2552](#2552) [#2555](#2555) [#2536](#2536) [#2537](#2537) [#2339](#2339) [#2349](#2349) [#2570](#2570) [#2462](#2462) [#2600](#2600) [#2468](#2468) [#2626](#2626) [#2621](#2621) [#2627](#2627) [#2644](#2644) [#2626](#2626) [#2645](#2645) [#2339](#2339) [#2643](#2643) [#2467](#2467) [#2690](#2690) [#2687](#2687) [#2722](#2722) [#2568](#2568) [#2726](#2726) [#2379](#2379) [#2289](#2289) [#2290](#2290) [#2304](#2304) [#2307](#2307) [#2314](#2314) [#2288](#2288) [#2305](#2305) [#2701](#2701) [#2568](#2568) [#2357](#2357) [#2552](#2552) [#2530](#2530) [#2559](#2559) [#2560](#2560) [#2564](#2564) [#2573](#2573) [#2584](#2584) [#2611](#2611) [#2635](#2635) [#2655](#2655) [#2658](#2658) [#2686](#2686) [#2711](#2711) [#2712](#2712) [#2736](#2736) [#2738](#2738) [#2747](#2747) [#2758](#2758) [#2647](#2647) [#2684](#2684) [#2638](#2638) [#2652](#2652) [#2662](#2662) [#2724](#2724) [#2767](#2767) [#2757](#2757) [#2610](#2610) [#2649](#2649) [#2520](#2520) [#2599](#2599) [#2506](#2506) [#2467](#2467) [#2626](#2626) [#2690](#2690) [#2688](#2688) [#2626](#2626) [#2726](#2726) [#2535](#2535) [#2461](#2461) [#2434](#2434) [#2687](#2687) [#2338](#2338) [#2179](#2179) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2189](#2189) [#2190](#2190) [#2179](#2179) [#2180](#2180) [#2181](#2181) [#2185](#2185) [#2192](#2192) [#2190](#2190) [#2536](#2536) [#2537](#2537) [#2834](#2834) [#2845](#2845) [#2842](#2842) [#2852](#2852) [#2853](#2853)

### BREAKING CHANGES

* **release:** translation will render default value if passed undefined as value

* chore(lodash): remove imports

* fix(translation): allow undefined value to be passed on purpose
* **release:** no longer do we allow paths like `attribute[5].something`, or other indexed forms, only `.` is allowed as special key.

All existing tests still pass, and we never documented you could use `lodash.get` patterns other than `.`.

* feat(get): accept array & bracked-separated string

moved to utils at the same time

* fix typo

* feedback: test for undefined behaviour

* chore(size): update expectation

this will go down afterwards, but for now there's some more duplication
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants