svelte-datepicker icon indicating copy to clipboard operation
svelte-datepicker copied to clipboard

bind to selected don't update selected

Open mblandr opened this issue 3 years ago • 2 comments

When I bind to selected property, there is no two-way binding, only component->variable. When I change variable, component doesn't update

mblandr avatar Feb 10 '22 13:02 mblandr

Folks, I'm stepping on this one a year later, is there any appetite for a PR to get two way binding in? I guess this is most useful in form scenarios.

auberryberry avatar May 03 '23 14:05 auberryberry

Key blocks worked for me.

{#key selected}
  <DatePicker
    {range}
    {placeholder}
    {format}
    {selected}
    {continueText}
    on:range-selected={(e) => handleRange(e)}
  />
{/key}

anastasiia-baboshina avatar Aug 24 '23 14:08 anastasiia-baboshina