Skip to content

Whitelisting conditions #19

@braco

Description

@braco

Great job on this library!

One thing: it seems important to support a whitelist of conditions. What if I wanted to search for text that had colons in it? Let's say a book is called "Foobar: The story of Steve", and a user tries to search for that phrase? You'll currently strip Foobar: out of the text.

Most query DSLs will have a specific set of conditions that are valid. search-query-parser shows their usage here. It would make sense to ignore anything else, imo.

I guess you'd need a breaking change that looked something like this: parse(string, { config })

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions