Instantsearch rangeSlider widget with attribute decimal values

I’m unable to get the range slider widget to work with decimal values.
I’d like the slider to go from 12 to 18 with steps in tenths of a unit.
Any ideas?

Here’s the codepen:

Hi @ryan.reid,

The built-in rangeSlider widget does not support float values. You can either pick an other widget (like RangeInput) or built your own slider with the connector API.

The rangeInput widget display two input that lets the end user type to refine a specific range of values (like the slider). You can control how many digits after decimal point to use with the precision attribute. Here is an example that shows how to use it.

The second option is to use the connector API. It lets you have the full control on what to render without having to re-implement all the logic of the search. You can use the connectRange connector to build your own slider with the library of your choice.

Hope that helps, let me know if you have questions.