summaryrefslogtreecommitdiff
path: root/iridescence/src/store
diff options
context:
space:
mode:
Diffstat (limited to 'iridescence/src/store')
-rw-r--r--iridescence/src/store/index.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/iridescence/src/store/index.js b/iridescence/src/store/index.js
index e2d970d..b324bd1 100644
--- a/iridescence/src/store/index.js
+++ b/iridescence/src/store/index.js
@@ -19,7 +19,13 @@ export default new Vuex.Store({
products(state) {
return state.products
.filter(item => {
- return JSON.stringify(item)
+ let haystack = [
+ item.id,
+ item.name,
+ item.description,
+ item.category
+ ].join("");
+ return haystack
.toLowerCase()
.includes(state.searchTerm.toLowerCase());
})