ui/utils/idleLogout

Methods

(inner) cookie()

Timeout function for renewing the access token used in module:/ui/utils/idleLogout~renewToken.

(inner) idleLogout(params)

A function for logging out inactive users. Inactivity is determined by no action occuring on the view within a certain amount of time.

The host and the amount of seconds can be specified in the params:

  {
    idle: 600,
    host: example.com
  }

-Idle is the duration in seconds -Host the calling url

The logout is achieved by deleting the session cookie.

Parameters:
NameTypeDescription
paramsObject

configuration options for the the idle state.

Properties
NameTypeAttributesDescription
params.idleNumber<optional>

The length of time in seconds that establishes the idle state.

params.hostString<optional>

The url host to be logged out of.

(inner) lock()

Function which logs the user out of the view by deleting the cookie and reloading the location.

(inner) renewToken()

Function for getting a new token if some action has taken place on the view.

(inner) resetTimer()

function for resetting the timeout in instances where an action occurs on the view.