@acctglobal/session-storage-client
Advanced tools
Comparing version 0.0.1 to 0.0.2
export class SessionStorageClient { | ||
constructor(sessionStorageKey) { | ||
this.storedData = {}; | ||
this.sessionStorageKey = sessionStorageKey; | ||
sessionStorage.setItem(sessionStorageKey, JSON.stringify({})); | ||
sessionStorage.setItem(sessionStorageKey, JSON.stringify(this.storedData)); | ||
} | ||
@@ -6,0 +7,0 @@ setProperty(propName, propValue) { |
{ | ||
"name": "@acctglobal/session-storage-client", | ||
"version": "0.0.1", | ||
"version": "0.0.2", | ||
"description": "Manages the session Storage", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
# SBD Authentication | ||
This repository contains app for Session Storage Client **Black&Dacker** | ||
This repository contains app for Session Storage Client **Black&Decker** | ||
## 🚀 Getting Started | ||
These instructions will allow you to get a copy of the project running on your local machine for the purposes of using the session storage client apps from the **Black&Dacker** store. | ||
These instructions will allow you to get a copy of the project running on your local machine for the purposes of using the session storage client apps from the **Black&Decker** store. | ||
@@ -55,3 +55,3 @@ ## 🔧 Installation | ||
- **Felipe Felix** - _Developer_ - [Felipe Felix](https://gitlab.com/felipe.felix1) | ||
- **Carlos Pelizzari** - _Archtect_ - [Carlos Pellizzari](https://gitlab.com/carlos.pellizzari) | ||
- **Carlos Pelizzari** - _Solutions Architect_ - [Carlos Pellizzari](https://gitlab.com/carlos.pellizzari) | ||
@@ -58,0 +58,0 @@ --- |
export class SessionStorageClient<T> { | ||
sessionStorageKey: string; | ||
storedData: T; | ||
storedData: T = {} as T; | ||
constructor(sessionStorageKey: string) { | ||
this.sessionStorageKey = sessionStorageKey; | ||
sessionStorage.setItem(sessionStorageKey, JSON.stringify({} as T)); | ||
sessionStorage.setItem(sessionStorageKey, JSON.stringify(this.storedData)); | ||
} | ||
@@ -9,0 +9,0 @@ |
Sorry, the diff of this file is not supported yet
5852
12
71