Preview:
# Store Pattern
subject = new BehaviorSubject<T>([]) // [] = default value
data$ = Observable<T> = this.subject.asObservable()

data = subject.getValue()
newState = data.slice(0)
subject.next(newState)
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter