feat(elements): implement NgElementConstructor

This commit is contained in:
George Kalpakas
2017-10-12 12:37:22 +03:00
committed by Victor Berchet
parent aed4a11d01
commit 0899f4f8fc
5 changed files with 500 additions and 0 deletions
+8
View File
@@ -11,6 +11,14 @@ export interface NgElement<T> extends HTMLElement {
markDirty(): void;
}
/** @experimental */
export interface NgElementConstructor<T, P> {
readonly is: string;
readonly observedAttributes: string[];
new (): NgElementWithProps<T, P>;
upgrade(host: HTMLElement): NgElementWithProps<T, P>;
}
/** @experimental */
export declare type NgElementWithProps<T, P> = NgElement<T> & {
[property in keyof