Skip to content

Commit e47e6b5

Browse files
committed
refactor(vue): replace instantsearch.js with instantsearch-core (#6440)
* refactor(vue): replace instantsearch.js with instantsearch-core [FX-3069] BREAKING CHANGE: if you are using any internal instantsearch.js functions, ensure to update to instantsearch-core to avoid duplication * fix! * fix for vue 2 * hup * prevent double search
1 parent 75ccd37 commit e47e6b5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+162
-195
lines changed

examples/vue/default-theme/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"dependencies": {
1111
"algoliasearch": "5.1.1",
1212
"core-js": "2",
13-
"instantsearch.js": "4.75.5",
13+
"instantsearch-core": "0.1.0",
1414
"vue": "2.7.14",
1515
"vue-instantsearch": "4.19.11"
1616
},

examples/vue/default-theme/src/App.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,8 +124,7 @@
124124

125125
<script>
126126
import { liteClient as algoliasearch } from 'algoliasearch/lite';
127-
import { history as historyRouter } from 'instantsearch.js/es/lib/routers';
128-
import { simple as simpleMapping } from 'instantsearch.js/es/lib/stateMappings';
127+
import { historyRouter, simpleStateMapping } from 'instantsearch-core';
129128
130129
import './App.css';
131130
@@ -140,7 +139,7 @@ export default {
140139
router: historyRouter({
141140
cleanUrlOnDispose: false,
142141
}),
143-
stateMapping: simpleMapping(),
142+
stateMapping: simpleStateMapping(),
144143
},
145144
};
146145
},

examples/vue/e-commerce/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"dependencies": {
1111
"algoliasearch": "5.1.1",
1212
"core-js": "2",
13-
"instantsearch.js": "4.75.5",
13+
"instantsearch-core": "0.1.0",
1414
"vue": "2.7.14",
1515
"vue-instantsearch": "4.19.11",
1616
"vue-slider-component": "3.0.32"

examples/vue/e-commerce/src/routing.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/* eslint-disable camelcase */
22
/* eslint-disable complexity */
3-
import { history as historyRouter } from 'instantsearch.js/es/lib/routers';
3+
import { historyRouter } from 'instantsearch-core';
44

55
const hitsPerPageItemsValue = [16, 32, 64];
66

examples/vue/e-commerce/src/widgets/ClearRefinements.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
</template>
1212

1313
<script>
14-
import { connectClearRefinements } from 'instantsearch.js/es/connectors';
14+
import { connectClearRefinements } from 'instantsearch-core';
1515
import { createWidgetMixin } from 'vue-instantsearch';
1616
1717
export default {

examples/vue/e-commerce/src/widgets/NoResults.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@
115115
</template>
116116

117117
<script>
118-
import { connectHits } from 'instantsearch.js/es/connectors';
118+
import { connectHits } from 'instantsearch-core';
119119
import { createWidgetMixin } from 'vue-instantsearch';
120120
121121
export default {

examples/vue/getting-started/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"dependencies": {
1010
"algoliasearch": "5.1.1",
1111
"core-js": "2",
12-
"instantsearch.js": "4.75.5",
12+
"instantsearch-core": "0.1.0",
1313
"vue": "2.7.14",
1414
"vue-instantsearch": "4.19.11"
1515
},

examples/vue/media/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"dependencies": {
1111
"algoliasearch": "5.1.1",
1212
"core-js": "2",
13-
"instantsearch.js": "4.75.5",
13+
"instantsearch-core": "0.1.0",
1414
"vue": "2.7.14",
1515
"vue-instantsearch": "4.19.11"
1616
},

examples/vue/media/src/App.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -113,8 +113,7 @@
113113

114114
<script>
115115
import { liteClient as algoliasearch } from 'algoliasearch/lite';
116-
import { history as historyRouter } from 'instantsearch.js/es/lib/routers';
117-
import { simple as simpleMapping } from 'instantsearch.js/es/lib/stateMappings';
116+
import { historyRouter, simpleStateMapping } from 'instantsearch-core';
118117
119118
import './App.css';
120119
@@ -129,7 +128,7 @@ export default {
129128
router: historyRouter({
130129
cleanUrlOnDispose: false,
131130
}),
132-
stateMapping: simpleMapping(),
131+
stateMapping: simpleStateMapping(),
133132
},
134133
};
135134
},

packages/vue-instantsearch/__mocks__/instantsearch.js/es.js

Lines changed: 0 additions & 73 deletions
This file was deleted.

0 commit comments

Comments
 (0)