Skip to content

Commit 0e16b92

Browse files
committed
Add info about getWritableSignal() to README.
1 parent c7bb68a commit 0e16b92

File tree

5 files changed

+20
-5
lines changed

5 files changed

+20
-5
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
### v1.2.1
2+
Add info about `getWritableSignal()` to README.
3+
14
### v1.2.0
25
Method `getWritableSignal()` will not write initial value to the storage anymore.
36

README.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,19 @@ export type ReactiveStorage = {
6767
*
6868
* If localStorage is being used as the storage, the value will be pushed synchronously.
6969
*/
70-
getSignal<T>(key: string): Signal<T | undefined>;
70+
getSignal<T>(key: string, options?: SignalOptions): Signal<T | undefined>;
71+
72+
73+
/**
74+
* Returns a signal with the current value for this key.
75+
* The key becomes "observed" and future modifications will be
76+
* written to the returned signal.
77+
*
78+
* The usage of the `set()` and `update()` methods of this signal will also update the storage key.
79+
*
80+
* If localStorage is being used as the storage, the value will be pushed synchronously.
81+
*/
82+
getWritableSignal<T>(key: string, options?: SignalOptions): WritableSignal<T | undefined>;
7183

7284
/**
7385
* Set a key-value pair

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ngx-reactive-storage",
3-
"version": "1.2.0",
3+
"version": "1.2.1",
44
"license": "MIT",
55
"author": {
66
"name": "Evgeniy OZ",

projects/ngx-reactive-storage/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "ngx-reactive-storage",
3-
"version": "1.2.0",
3+
"version": "1.2.1",
44
"license": "MIT",
55
"private": false,
66
"author": {

0 commit comments

Comments
 (0)