v-autocomplete icon indicating copy to clipboard operation
v-autocomplete copied to clipboard

Remove value changes loop - emit event on item select and react on incoming value change

Open gorbunovav opened this issue 6 years ago • 2 comments

…oming value change

gorbunovav avatar Mar 28 '18 13:03 gorbunovav

Hey @gorbunovav, could you add a bit of details regarding this PR, i.e. what it changes and why it's useful? I'm working around the same piece of functionality at the moment at would like to understand whether my thinking is correct.

killthekitten avatar Aug 13 '18 11:08 killthekitten

Hi @killthekitten! The goal of this PR is to implement one-way data flow and avoid state duplication inside the component. On each change, the component emits an event and the parent updates own state, then the state change is propagated to the component via the bound property.

https://vuejs.org/v2/guide/components-props.html#One-Way-Data-Flow

gorbunovav avatar Aug 13 '18 12:08 gorbunovav