This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export const LOGIC_HANDLER = new InjectionToken<CaseLogicHandler>('logic.handlers'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export interface CaseLogicHandler { | |
key: any; | |
doLogic(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export class CaseOne implements CaseLogicHandler{ | |
key: any = 1; | |
doLogic() { | |
// case logic | |
} | |
} | |
export class CaseTwo implements CaseLogicHandler{ | |
key: any = 2; | |
doLogic() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Directive({ | |
selector: '[myDir]' | |
}) | |
export class MyDirDirective { | |
constructor(public template: TemplateRef<any>) { | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Component({ | |
template:` | |
<div popover="popoverOne"> | |
// content | |
</div> | |
<div popover="popoverTwo"> | |
// content |
NewerOlder