Skip to content

Instantly share code, notes, and snippets.

@couzic
Last active April 7, 2017 21:50
Show Gist options
  • Select an option

  • Save couzic/846da33042b4c4b627b54862361b80ca to your computer and use it in GitHub Desktop.

Select an option

Save couzic/846da33042b4c4b627b54862361b80ca to your computer and use it in GitHub Desktop.
Temporal Transparency - Counter Example
import {Observable} from 'rxjs'
let count = 0
export const counter = {
increment() {
++count
}
getCount(): Observable<number> {
return Observable.of(count)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment