diff --git a/tests/env/react/src/App.js b/tests/env/react/src/App.js
index cef98d011..efd234b20 100644
--- a/tests/env/react/src/App.js
+++ b/tests/env/react/src/App.js
@@ -2,6 +2,7 @@ import React from 'react'
import { Routes, Route, Outlet } from 'react-router-dom'
import SingleIndex from './components/SingleIndex'
import MultiIndex from './components/MultiIndex'
+import SingleMovieIndex from './components/SingleMovieIndex'
import './App.css'
@@ -11,6 +12,7 @@ const App = () => {
} />
} />
+ } />
diff --git a/tests/env/react/src/components/MultiIndex.js b/tests/env/react/src/components/MultiIndex.js
index 5da3b349a..61b9d0458 100644
--- a/tests/env/react/src/components/MultiIndex.js
+++ b/tests/env/react/src/components/MultiIndex.js
@@ -6,14 +6,16 @@ import {
Highlight,
RefinementList,
Index,
- Hits,
+ InfiniteHits,
Pagination,
+ Hits,
} from 'react-instantsearch-dom'
import { instantMeiliSearch } from '../../../../../src/index'
const searchClient = instantMeiliSearch('http://localhost:7700', 'masterKey', {
primaryKey: 'id',
finitePagination: true,
+ keepZeroFacets: true,
})
const Hit = ({ hit }) => {
@@ -40,7 +42,7 @@ const MultiIndex = () => (
Genres
Color
-
+
Platforms
@@ -62,9 +64,8 @@ const MultiIndex = () => (
-
+
-
diff --git a/tests/env/react/src/components/SingleIndex.js b/tests/env/react/src/components/SingleIndex.js
index cc5b9dc68..a946c9ffb 100644
--- a/tests/env/react/src/components/SingleIndex.js
+++ b/tests/env/react/src/components/SingleIndex.js
@@ -2,7 +2,6 @@ import 'instantsearch.css/themes/algolia-min.css'
import React from 'react'
import {
InstantSearch,
- InfiniteHits,
SearchBox,
Stats,
Highlight,
@@ -11,11 +10,16 @@ import {
Configure,
SortBy,
Snippet,
+ Pagination,
+ Hits,
} from 'react-instantsearch-dom'
import { instantMeiliSearch } from '../../../../../src/index'
const searchClient = instantMeiliSearch('http://localhost:7700', 'masterKey', {
primaryKey: 'id',
+ placeholderSearch: false,
+ finitePagination: true,
+ keepZeroFacets: true,
})
const SingleIndex = () => (
@@ -58,14 +62,15 @@ const SingleIndex = () => (
Misc
diff --git a/tests/env/react/src/components/SingleMovieIndex.js b/tests/env/react/src/components/SingleMovieIndex.js
new file mode 100644
index 000000000..119110d3f
--- /dev/null
+++ b/tests/env/react/src/components/SingleMovieIndex.js
@@ -0,0 +1,62 @@
+import 'instantsearch.css/themes/algolia-min.css'
+import React from 'react'
+import {
+ InstantSearch,
+ InfiniteHits,
+ SearchBox,
+ Stats,
+ Highlight,
+ ClearRefinements,
+ RefinementList,
+} from 'react-instantsearch-dom'
+import { instantMeiliSearch } from '../../../../../src/index'
+
+const searchClient = instantMeiliSearch('http://localhost:7700', 'masterKey', {
+ primaryKey: 'id',
+ keepZeroFacets: true,
+})
+
+const SingleIndex = () => (
+
+
Meilisearch + React InstantSearch
+
Search in movies
+
+
+
+
+
+
Genres
+
+ Players
+
+ Platforms
+
+
+
+
+
+
+
+
+)
+
+const Hit = ({ hit }) => {
+ return (
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ )
+}
+
+export default SingleIndex