Handle node, chromeapp, and browser localStore