UNPKG

@ark-ui/vue

Version:

A collection of unstyled, accessible UI components for Vue, utilizing state machines for seamless interaction.

15 lines (13 loc) 357 B
const createSplitProps = () => (props, keys) => keys.reduce( (previousValue, currentValue) => { const [target, source] = previousValue; const key = currentValue; if (source[key] !== void 0) { target[key] = source[key]; } delete source[key]; return [target, source]; }, [{}, { ...props }] ); export { createSplitProps };