Values & Binding
Setting the default value(s) for the Slider is done using the values
property, which accepts an Array[]
. The values
property can have any number of values, and the length directly corresponds to the number of handles on the Slider. The values
are limited to the given min
and max
range.
Simple Values
Binding
The values
property can also be bound with bind:values
. This allows the Slider to save the current value(s) to a variable.
Multiple Values
The values
property can also accept multiple values. This allows the Slider to have multiple handles. The values are stored in an array. The length of the array corresponds to the number of handles on the Slider.
No idea why anyone would ever want 9 handles on their Slider, but it’s totally possible!