Skip to content
This repository has been archived by the owner on May 31, 2024. It is now read-only.

Commit

Permalink
Feature/louis update storage (#29)
Browse files Browse the repository at this point in the history
* feat: update prefix func

* docs: update CHANGELOG
  • Loading branch information
louis-lemon authored Nov 20, 2023
1 parent a19405c commit 9da2116
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# @lemoncloud/lemon-front-lib

## 1.3.13

### Patch Changes

- add updatePrefix function to storage service

## 1.3.12

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@lemoncloud/lemon-front-lib",
"version": "1.3.12",
"version": "1.3.13",
"description": "Web Core Library for Lemoncloud",
"exports": "./dist/index.js",
"types": "./dist/index.d.ts",
Expand Down
4 changes: 4 additions & 0 deletions src/core/lemon-storage.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ export class LemonStorageService {
this.storageService = storage;
}

updatePrefix(prefix: string) {
this.prefix = `@${prefix}`;
}

async setItem(key: string, value: string) {
return await this.storageService.setItem(`${this.prefix}.${key}`, value);
}
Expand Down

0 comments on commit 9da2116

Please sign in to comment.