Open DavertMik opened 1 year ago
Description It would be nice if this gem could to eager load relations of matched records
class Book scope with_author: -> { includes(:author) } end Book.search('Harry Potter', scope: :with_author)
I would add an optional scope parameter and used it here to load relations https://github.com/meilisearch/meilisearch-rails/blob/main/lib/meilisearch-rails.rb#L653
Hi @DavertMik sorry for the late reply. Indeed it would be a nice addition, I go further if we had something like this:
Book.with_author.with_reviews.search('Harry Potter')
Description It would be nice if this gem could to eager load relations of matched records
I would add an optional scope parameter and used it here to load relations https://github.com/meilisearch/meilisearch-rails/blob/main/lib/meilisearch-rails.rb#L653