rxjs observable angular 2 on localstorage change
问题 I am trying to create an observable that returns values when changes to a localStorage variable happens. My subscriber is not getting the new values upon changes to localStorage (or for that matter an in memory variable). navbar.component.js import { Component, OnInit } from '@angular/core'; import { UserService } from '../services/user.service'; /** * This class represents the navigation bar component. */ @Component({ moduleId: module.id, selector: 'sd-navbar', templateUrl: 'navbar.component