reblendjs
Version:
ReblendJs uses Reactjs pradigm to build UI components, with isolated state for each components.
18 lines (17 loc) • 1.06 kB
TypeScript
import * as ReblendTyping from 'reblend-typing';
/**
* Sets properties on the target component, updating attributes and handling special cases like events and style.
*
* @param {ReblendTyping.IAny} props - The properties to set.
* @param {ReblendTyping.Component} to - The target component to apply the properties to.
* @param {boolean} init - Whether this is an initial setting of properties.
*/
export declare function setProps<P, S, ExpectedReturn = any>(props: ReblendTyping.IAny, to: ReblendTyping.Component<P, S>, init: boolean): Promise<ExpectedReturn>;
/**
* Removes specified properties from the `to` component and removes the corresponding attributes.
* If a property is to be removed using `setAttribute`, it will also be removed from `props`.
*
* @param {ReblendTyping.IAny} props - The properties to remove from the component.
* @param {ReblendTyping.Component} to - The target component from which to remove the properties.
*/
export declare function removeProps<P, S>(props: ReblendTyping.IAny, to: ReblendTyping.Component<P, S>): void;