farzher / fuzzysort

Fast SublimeText-like fuzzy search for JavaScript.

Home Page:https://rawgit.com/farzher/fuzzysort/master/test/test.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

I am only getting exact matches

stenes90 opened this issue · comments

Hello,
I am using fuzzysort for some time and it worked perfectly for me since yesterday. I do not have any change in the code but I can notice that the results are pretty different. Looks like it is only returning perfect matches.
const list = [
{ name: "SAMSUNG UE32T4002AKXXH" },
{ name: "Samsung LED 32T4302AK SMART" },
{ name: "SAMSUNG UE 32T4002AK 32 HD LED TV" },
{ name: "TV Samsung UE32T4002AK 32 LED HD HDMIx2 USB DVB C T2" },
{ name: "TV Samsung UE32T4302AK 32 Smart LED HD HDMIx2 " },
];

  let results = fuzzysort.go("SAMSUNG UE32T4002AKXXH", list, {
    keys: ["name"],
  });

I am getting only 1 result as an output, and in the past I had 3 results for this case
//OUTPUT: { name: "SAMSUNG UE32T4002AKXXH"} - score 0

I also tried with very high treashold but I am getting same results. I am really confused how can this happen. Any advice here how can I get better results? Previously I was getting #1, #3 and #4 as a result.
Btw you have made a great tool!Tnx a lot