Skip to content

Commit

Permalink
Merge branch 'feat/instantsearch.js/v2' of github.com:algolia/instant…
Browse files Browse the repository at this point in the history
…search.js into feat/instantsearch.js/v2
  • Loading branch information
iam4x committed May 12, 2017
2 parents 237c22e + 5ea41fa commit 70aae51
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
16 changes: 8 additions & 8 deletions docgen/src/widgets.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ on...
Widgets can be added to the InstantSearch instance using the `addWidget` method.

```javascript
var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.searchbox(/* searchbox parameters */));
```

Expand All @@ -42,7 +42,7 @@ may be unpredictable.
This is usually one of the only attribute required to use a widget.

```javascript
var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.searchbox({
container: '#my-searchbox',
}));
Expand All @@ -56,7 +56,7 @@ an object of either string or array of strings. The different keys available
is define in the widget reference.

```javascript
var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.searchbox({
container: '#search-box',
cssClasses: {
Expand All @@ -78,7 +78,7 @@ Like the css classes they can only be written for some specific parts of the ren
widget.

```javascript
var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.refinementList({
container: '#hits',
templates: {
Expand Down Expand Up @@ -107,7 +107,7 @@ return an object. Usually, it is an enhanced version of the original object with
new properties.

```javascript
var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.refinementList({
container: '#categories',
attribute: 'categories',
Expand All @@ -134,7 +134,7 @@ like the property is true and you can defined it's initial state using the prope
`collapsed`.

```javascript
var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.refinementList({
container: '#categories',
attribute: 'categories',
Expand All @@ -143,7 +143,7 @@ search.addWidget(instantsearch.refinementList({

// OR for an initially collapsed refinement list

var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.refinementList({
container: '#categories',
attribute: 'categories',
Expand All @@ -161,7 +161,7 @@ This can help the users focus on the important like the current refined values s
they can remove some filters.
```javascript
var search = instantsearch(/* parameters here */);
const search = instantsearch(/* parameters here */);
search.addWidget(instantsearch.refinementList({
container: '#categories',
attribute: 'categories',
Expand Down
2 changes: 1 addition & 1 deletion src/connectors/refinement-list/connectRefinementList.js
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ export default function connectRefinementList(renderFn) {
});
} else {
helper.searchForFacetValues(attributeName, query).then(results => {
const facetValues = results.facetHits.map(formatItems);
const facetValues = results.facetHits;

render({
items: facetValues,
Expand Down

0 comments on commit 70aae51

Please sign in to comment.