ngx-decorate
Version:
Useful decorators for Angular 2 and above
20 lines (19 loc) • 728 B
TypeScript
import { ConfEnum } from './type/ConfEnum';
export interface CdrPropConfig {
/** Default value to set on the prototype */
default?: any;
/** Partial property descriptor */
desc?: ConfEnum;
/**
* Key of a property used for tracking whether the component's been destroyed
* to prevent errors caused by triggering change detection on a destroyed component.
*/
destroyed?: PropertyKey;
}
/**
* Call .markForCheck() on the change detector ref whenever this property is written to.
*
* @param propName Property at which the change detector can be found
* @param conf Optional configuration
*/
export declare function CdrProp(propName: PropertyKey, conf?: CdrPropConfig): PropertyDecorator;