import React from 'react';
/**
 * Component creation utility, which combines forwardRef, memo and ensures correct typing with all props included.
 * Config object allows toggling memoization and providing custom 'areEqual' function.
 */
export function vui(component, config) {
    const { memoCompare, isMemo = true } = config ?? {};
    if (isMemo) {
        return React.memo(React.forwardRef(component), memoCompare);
    }
    return React.forwardRef(component);
}
export default vui;
//# sourceMappingURL=vui.js.map