Created
February 8, 2017 02:21
-
-
Save uxder/b7b84d8c82d92849ca269c61a8c95abf to your computer and use it in GitHub Desktop.
Mike example
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 { BehaviorSubject } from 'rxjs/BehaviorSubject'; | |
class ExampleForMike { | |
private userStream$: BehaviorSubject<any>; | |
public getStream():BehaviorSubject<> { | |
return this.userStream$; | |
} | |
public getNameStream():BehaviorSubject<> { | |
return this.userStream$.map((data) => { return data.firstName + ' ' + data.lastName } | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment