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 function ContentChildrenChanges() { | |
return function (target, propertyKey) { | |
if (!isContentChanges(target)) { | |
return; | |
} | |
// Grab reference to toriginal `ngOnDestroy()` hook |
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
import { Injectable, Inject } from "@angular/core"; | |
import { ParsedUrl } from './url/url.interfaces'; | |
import { AppResolverOptions, APP_RESOLVER_OPTIONS } from './app-launcher.interfaces'; | |
@Injectable() | |
export class AppResolver { | |
constructor( | |
@Inject(APP_RESOLVER_OPTIONS) private options: AppResolverOptions | |
) {} |
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
import { createSelector } from '@ngrx/store'; | |
import { State } from './reducer.ts'; | |
export const selectTodosCount = createSelector((state: State): number => { | |
return Object.keys(state).length; | |
}); |
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
import { Todo } from './model'; | |
export interface State { | |
[id: string]: Todo | |
} | |
export function reducer(state: State, action): State { | |
switch (action.type) { | |
case Types.ADD_TODO: | |
const id = action.payload.id; |
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
$ ng build --app foo && ng build --app bar && ng build --app foo-bar | |
Date: 2018-01-12T16:08:36.058Z | |
Hash: c74c6a1b18230624c8ba | |
Time: 7337ms | |
chunk {inline} inline.bundle.js, inline.bundle.js.map (inline) 5.83 kB [entry] [rendered] | |
chunk {main} main.bundle.js, main.bundle.js.map (main) 8.33 kB [initial] [rendered] | |
chunk {polyfills} polyfills.bundle.js, polyfills.bundle.js.map (polyfills) 201 kB [initial] [rendered] | |
chunk {styles} styles.bundle.js, styles.bundle.js.map (styles) 11.4 kB [initial] [rendered] | |
chunk {vendor} vendor.bundle.js, vendor.bundle.js.map (vendor) 2.43 MB [initial] [rendered] | |
Date: 2018-01-12T16:08:45.721Z |
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
$ mvn install | |
[INFO] Scanning for projects... | |
[INFO] ------------------------------------------------------------------------ | |
[INFO] Reactor Build Order: | |
[INFO] | |
[INFO] minimal-pom | |
[INFO] angular-product-bar | |
[INFO] angular-product-foo | |
[INFO] angular-product-foo-bar | |
[INFO] |
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 type MyStuff = string; | |
export interface Event<T> { | |
type: 'Starts' | 'Finishes', | |
payload: T | |
} | |
/** @experimental */ | |
export class Bus<P> extends Subject<Event<P>> { |
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
{ | |
"__symbolic": "module", | |
"version": 4, | |
"metadata": { | |
"SelectableListModule": { | |
"__symbolic": "class", | |
"decorators": [ | |
{ | |
"__symbolic": "call", | |
"expression": { |
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
/** | |
* Visits a Node using the supplied visitor, possibly returning a new Node in its place. | |
*/ | |
function visitNode<T extends Node>(node: T, visitor: Visitor): T; | |
/** | |
* Visits a NodeArray using the supplied visitor, possibly returning a new NodeArray in | |
* its place. | |
*/ | |
function visitNodes<T extends Node>(nodes: NodeArray<T>, visitor: Visitor): NodeArray<T>; |
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({ | |
selector: 'app-function-works', | |
templateUrl: './function-works.component.html', | |
styleUrls: ['./function-works.component.css'] | |
}) | |
export class FunctionWorksComponent implements OnInit { | |
message = 'foo'; | |
constructor() { } |
NewerOlder