@kokimoki/app 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -11,6 +11,7 @@ export declare class KokimokiStore<T extends S.Generic<unknown>, SubscribeT = T[
11
11
  readonly defaultValue: T["defaultValue"];
12
12
  readonly docRoot: Y.Map<unknown>;
13
13
  constructor(roomName: string, schema: T, mode?: RoomSubscriptionMode);
14
+ get(): T["defaultValue"];
14
15
  subscribe(set: (value: SubscribeT) => void): () => void;
15
16
  onJoin(client: KokimokiClient): Promise<void>;
16
17
  onBeforeLeave(client: KokimokiClient): Promise<void>;
@@ -45,6 +45,9 @@ export class KokimokiStore {
45
45
  // Set default value
46
46
  this.defaultValue = schema.defaultValue;
47
47
  }
48
+ get() {
49
+ return this.proxy;
50
+ }
48
51
  subscribe(set) {
49
52
  // @ts-ignore
50
53
  const handler = () => set(this.proxy);
@@ -220,6 +220,7 @@ declare class KokimokiStore<T extends KokimokiSchema.Generic<unknown>, Subscribe
220
220
  readonly defaultValue: T["defaultValue"];
221
221
  readonly docRoot: Y.Map<unknown>;
222
222
  constructor(roomName: string, schema: T, mode?: RoomSubscriptionMode);
223
+ get(): T["defaultValue"];
223
224
  subscribe(set: (value: SubscribeT) => void): () => void;
224
225
  onJoin(client: KokimokiClient): Promise<void>;
225
226
  onBeforeLeave(client: KokimokiClient): Promise<void>;
@@ -634,7 +634,7 @@ function eventTargetAgnosticAddListener(emitter, name, listener, flags) {
634
634
  var eventsExports = events.exports;
635
635
  var EventEmitter$1 = /*@__PURE__*/getDefaultExportFromCjs(eventsExports);
636
636
 
637
- const KOKIMOKI_APP_VERSION = "1.1.0";
637
+ const KOKIMOKI_APP_VERSION = "1.1.1";
638
638
 
639
639
  /**
640
640
  * Utility module to work with key-value stores.
@@ -12448,6 +12448,9 @@ class KokimokiStore {
12448
12448
  // Set default value
12449
12449
  this.defaultValue = schema.defaultValue;
12450
12450
  }
12451
+ get() {
12452
+ return this.proxy;
12453
+ }
12451
12454
  subscribe(set) {
12452
12455
  // @ts-ignore
12453
12456
  const handler = () => set(this.proxy);