|
Hi, I'm having trouble tuning the search parameters. I'm trying to replace the search function in Topola Viewer with fuse.js. The search is over people's names. I tried indexing a person's name as See this code sample for my examples: https://stackblitz.com/edit/typescript-y8hfkk?file=index.ts In short, case 1 indexes: const list = [
{ name: ['tomasz', 'wozniak'] },
{ name: ['dominik', 'wozniak'] },
];and the search for Case 2 indexes: const list = [
{ name: 'tomasz wozniak' },
{ name: 'igor wozniak' }
];and the search for Please help me tweak the indexing and search options. Or am I doing something wrong? |
Replies: 1 comment
|
I would recommend you first transform your search list, separating the names into individual properties: const list = [
{ first: 'tomasz', lastName: 'wozniak' },
{ first: 'dominik', lastName: 'wozniak' }
]; |
I would recommend you first transform your search list, separating the names into individual properties: