josefarias / hotwire_combobox

An accessible autocomplete for Ruby on Rails.
https://hotwirecombobox.com
MIT License
436 stars 26 forks source link

Pass in query params to default async src #135

Closed dixpac closed 4 months ago

dixpac commented 4 months ago

Before, default src was set using request.path which returns virtual path without query string.

This PR changes default implementation to use request.fullpath which returns virtual path with query string.

Form example; In our app we have one controller endpoint where we filter the results not just base on user entry q but also query strings.

josefarias commented 4 months ago

Great change @dixpac! Thanks for tackling.

Left one comment. I think once we address that and add a test for this we'll be ready to merge.

dixpac commented 4 months ago

@josefarias added stringify_keys and a simple test

josefarias commented 4 months ago

Awesome. Thanks for tackling @dixpac!