/**
 * It's a concept that's being considered for addition
 *
 * This code allows the builder to expose only certain properties of a component.
 * But do users accept this type of operation?
 */
declare class Component {
    getProps(): unknown;
}
declare class DrivedComponent extends Component {
    value1: number;
}
interface DrivedComponent2Props {
    value1: number;
    func1: (value: number) => number;
}
declare class DrivedComponent2 extends Component {
    getProps(): DrivedComponent2Props;
    value1: number;
    func1: (value: number) => number;
    func2: (value: number) => number;
}
type UnwrapUnknown<T> = T extends unknown ? unknown extends T ? never : T : T;
type GetProps<T extends Component> = T["getProps"] extends (() => infer U) ? UnwrapUnknown<U> : never;
type GetPropsOrComponent<T extends Component> = GetProps<T> extends never ? T : GetProps<T>;
declare function withComponent<T extends Component>(componentCtor: new (...args: any[]) => T, callback: (component: GetPropsOrComponent<T>) => void): void;
