Module: ko/session-storage

session-storage module which lets you store session data

For storing preferences (user facing persistent data) use ko/prefs

For persistent data check out module:ko/simple-storage

Example

var ss = require("ko/session-storage").get("foo").storage;
ss.foobar = "foo";

Methods


require("ko/session-storage").get(name)

Get session data for the given name (will be created if it doesnt exist)

Use the storage property to write and retrieve data.

Parameters:
Name Type Description
name String
Returns:

{storage: {}}

Type
Object

require("ko/session-storage").remove(name)

Remove/purge all session data for the given name

Parameters:
Name Type Description
name String