feat(UpgradeComponent): add support for require
This commit also adds/improves/fixes some `UpgradeComponent` tests.
This commit is contained in:

committed by
vikerman

parent
469010ea8e
commit
fe1d0e29c5
@ -12,6 +12,8 @@ export interface IAnnotatedFunction extends Function { $inject?: Ng1Token[]; }
|
||||
|
||||
export type IInjectable = (Ng1Token | Function)[] | IAnnotatedFunction;
|
||||
|
||||
export type SingleOrListOrMap<T> = T | T[] | {[key: string]: T};
|
||||
|
||||
export interface IModule {
|
||||
name: string;
|
||||
requires: (string|IInjectable)[];
|
||||
@ -44,6 +46,7 @@ export interface IRootScopeService {
|
||||
$apply(): any;
|
||||
$apply(exp: string): any;
|
||||
$apply(exp: Function): any;
|
||||
$digest(): any;
|
||||
$evalAsync(): any;
|
||||
$on(event: string, fn?: (event?: any, ...args: any[]) => void): Function;
|
||||
$$childTail: IScope;
|
||||
@ -72,7 +75,7 @@ export interface IDirective {
|
||||
terminal?: boolean;
|
||||
transclude?: boolean|'element'|{[key: string]: string};
|
||||
}
|
||||
export type DirectiveRequireProperty = Ng1Token[] | Ng1Token | {[key: string]: Ng1Token};
|
||||
export type DirectiveRequireProperty = SingleOrListOrMap<string>;
|
||||
export interface IDirectiveCompileFn {
|
||||
(templateElement: IAugmentedJQuery, templateAttributes: IAttributes,
|
||||
transclude: ITranscludeFunction): IDirectivePrePost;
|
||||
|
Reference in New Issue
Block a user