Skip to content

Not detecting multiple instances of the search target in the same line #146

@MTG2000

Description

@MTG2000

Hi 👋

I'm not sure if this is the intended behaviour, but I noticed that when there are multiple occurrences of the search term in a line, only one of them is detected and added to the indexes array.

You can see this behaviour on the demo page:
https://rawgit.com/farzher/fuzzysort/master/test/test.html

Notice how Youtube is only highlighted once in the first search result even though it appears 2 times.
Image

Is this intentional?
Cause I think right now, it might be confusing/misleading to the user when he types a search term & it's not being highlighted in some places making him maybe miss it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions