New gem for search forms and sort links: talent_scout

talent_scout is a gem for searching and sorting:

I wrote talent_scout because existing gems for searching and sorting had shortcomings that I couldn’t easily fix. Their view helpers seemed cumbersome (or were non-existent), and I had security and performance concerns about the kinds of queries the helpers could build.

In comparison, talent_scout creates a search object that can be used directly with Rails’ form_with. It provides helpers for creating both search links (e.g. facet links) and sort links. Queries are based on predefined scopes, which helps mitigate security and performance issues. And it handles typecasting user inputs, invalid user inputs, and omitted user inputs.

I’ve tried to make the talent_scout README and docs as thorough as possible, but I would be delighted to answer any questions. Feedback is welcome!