@base-ui-components/react
Version:
Base UI is a library of headless ('unstyled') React components and low-level hooks. You gain complete control over your app's CSS and accessibility features.
8 lines • 323 B
JavaScript
import * as React from 'react';
import { mergeReactProps } from './mergeReactProps.js';
export function evaluateRenderProp(render, props, state) {
return typeof render === 'function' ? render(props, state) : /*#__PURE__*/React.cloneElement(render, {
...mergeReactProps(render.props, props),
ref: props.ref
});
}