Skip to content

Documentation / @ripl/vue / collectChangedProps

Function: collectChangedProps() ​

collectChangedProps(props, keys, applied): RiplWritable | undefined

Defined in: adapters/vue/src/core/state.ts:78

Reads the bound props, folding any that differ from applied into a changed batch.

Writes through to applied so the caller keeps no second snapshot, and returns undefined rather than an empty object, so a tick that changed nothing costs no allocation at all.

Parameters ​

ParameterTypeDescription
propsRiplWritableThe component's props object.
keysreadonly string[]Every prop name to keep in sync.
appliedRiplWritableThe values last written to the element; mutated in place.

Returns ​

RiplWritable | undefined

The changed props, or undefined when none changed.