reactronic 0.23.111 → 0.23.112
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.
- package/build/dist/source/Options.d.ts +11 -0
- package/build/dist/source/{Buffer.d.ts → Pipe.d.ts} +2 -2
- package/build/dist/source/{Buffer.js → Pipe.js} +1 -1
- package/build/dist/source/Reaction.d.ts +2 -13
- package/build/dist/source/Reaction.js +3 -1
- package/build/dist/source/Rx.d.ts +1 -2
- package/build/dist/source/api.d.ts +1 -2
- package/build/dist/source/impl/Reaction.d.ts +1 -2
- package/package.json +6 -6
|
@@ -37,3 +37,14 @@ export declare enum Reentrance {
|
|
|
37
37
|
OverwritePrevious = -3,
|
|
38
38
|
RunSideBySide = -4
|
|
39
39
|
}
|
|
40
|
+
export interface AbstractReaction<T> {
|
|
41
|
+
readonly options: MemberOptions;
|
|
42
|
+
readonly args: ReadonlyArray<any>;
|
|
43
|
+
readonly result: T;
|
|
44
|
+
readonly error: any;
|
|
45
|
+
readonly stamp: number;
|
|
46
|
+
readonly isUpToDate: boolean;
|
|
47
|
+
configure(options: Partial<MemberOptions>): MemberOptions;
|
|
48
|
+
markObsolete(): void;
|
|
49
|
+
pullLastResult(args?: any[]): T | undefined;
|
|
50
|
+
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { ObservableObject } from './impl/Mvcc.js';
|
|
2
|
-
export declare abstract class
|
|
2
|
+
export declare abstract class Pipe<T> extends ObservableObject {
|
|
3
3
|
abstract readonly capacity: number;
|
|
4
4
|
abstract readonly count: number;
|
|
5
5
|
abstract put(...items: T[]): void;
|
|
6
6
|
abstract take(count: number): T[];
|
|
7
|
-
static create<T>(hint?: string, capacity?: number):
|
|
7
|
+
static create<T>(hint?: string, capacity?: number): Pipe<T>;
|
|
8
8
|
}
|
|
@@ -1,17 +1,6 @@
|
|
|
1
1
|
import { F } from './util/Utils.js';
|
|
2
|
-
import {
|
|
3
|
-
export
|
|
4
|
-
readonly options: MemberOptions;
|
|
5
|
-
readonly args: ReadonlyArray<any>;
|
|
6
|
-
readonly result: T;
|
|
7
|
-
readonly error: any;
|
|
8
|
-
readonly stamp: number;
|
|
9
|
-
readonly isUpToDate: boolean;
|
|
10
|
-
configure(options: Partial<MemberOptions>): MemberOptions;
|
|
11
|
-
markObsolete(): void;
|
|
12
|
-
pullLastResult(args?: any[]): T | undefined;
|
|
13
|
-
}
|
|
14
|
-
export declare class Reaction<T> {
|
|
2
|
+
import { ObservableObject } from './impl/Mvcc.js';
|
|
3
|
+
export declare class Reaction<T> extends ObservableObject {
|
|
15
4
|
protected action: F<T>;
|
|
16
5
|
constructor(action: F<T>);
|
|
17
6
|
protected launch(): T;
|
|
@@ -7,9 +7,11 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
7
7
|
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
8
8
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
9
9
|
};
|
|
10
|
+
import { ObservableObject } from './impl/Mvcc.js';
|
|
10
11
|
import { reactive } from './Rx.js';
|
|
11
|
-
export class Reaction {
|
|
12
|
+
export class Reaction extends ObservableObject {
|
|
12
13
|
constructor(action) {
|
|
14
|
+
super();
|
|
13
15
|
this.action = action;
|
|
14
16
|
}
|
|
15
17
|
launch() {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { F } from './util/Utils.js';
|
|
2
|
-
import { AbstractReaction } from './
|
|
3
|
-
import { MemberOptions, LoggingOptions, ProfilingOptions } from './Options.js';
|
|
2
|
+
import { AbstractReaction, MemberOptions, LoggingOptions, ProfilingOptions } from './Options.js';
|
|
4
3
|
export declare class Rx {
|
|
5
4
|
static why(brief?: boolean): string;
|
|
6
5
|
static getReaction<T>(method: F<T>): AbstractReaction<T>;
|
|
@@ -5,9 +5,8 @@ export { SealedArray } from './util/SealedArray.js';
|
|
|
5
5
|
export { SealedMap } from './util/SealedMap.js';
|
|
6
6
|
export { SealedSet } from './util/SealedSet.js';
|
|
7
7
|
export { Kind, Reentrance, LoggingLevel } from './Options.js';
|
|
8
|
-
export type { MemberOptions, SnapshotOptions, LoggingOptions, ProfilingOptions } from './Options.js';
|
|
8
|
+
export type { AbstractReaction, MemberOptions, SnapshotOptions, LoggingOptions, ProfilingOptions } from './Options.js';
|
|
9
9
|
export type { Worker } from './Worker.js';
|
|
10
|
-
export type { AbstractReaction } from './Reaction.js';
|
|
11
10
|
export { Ref, ToggleRef, refs, toggleRefs, customToggleRefs } from './Ref.js';
|
|
12
11
|
export type { BoolOnly, GivenTypeOnly } from './Ref.js';
|
|
13
12
|
export { TransactionalObject, ObservableObject } from './impl/Mvcc.js';
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { F } from '../util/Utils.js';
|
|
2
|
-
import { MemberOptions } from '../Options.js';
|
|
3
|
-
import { AbstractReaction } from '../Reaction.js';
|
|
2
|
+
import { AbstractReaction, MemberOptions } from '../Options.js';
|
|
4
3
|
import { MemberName, ObjectHandle, ValueSnapshot, Observer, Subscription, AbstractChangeset } from './Data.js';
|
|
5
4
|
import { Transaction } from './Transaction.js';
|
|
6
5
|
import { OptionsImpl } from './Mvcc.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "reactronic",
|
|
3
|
-
"version": "0.23.
|
|
3
|
+
"version": "0.23.112",
|
|
4
4
|
"description": "Reactronic - Transactional Reactive State Management",
|
|
5
5
|
"publisher": "Nezaboodka Software",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -31,13 +31,13 @@
|
|
|
31
31
|
},
|
|
32
32
|
"homepage": "https://github.com/nezaboodka/reactronic/blob/master/README.md#readme",
|
|
33
33
|
"devDependencies": {
|
|
34
|
-
"@types/node": "20.
|
|
35
|
-
"@types/react": "18.2.
|
|
36
|
-
"@typescript-eslint/eslint-plugin": "6.
|
|
37
|
-
"@typescript-eslint/parser": "6.
|
|
34
|
+
"@types/node": "20.10.0",
|
|
35
|
+
"@types/react": "18.2.39",
|
|
36
|
+
"@typescript-eslint/eslint-plugin": "6.13.1",
|
|
37
|
+
"@typescript-eslint/parser": "6.13.1",
|
|
38
38
|
"ava": "5.3.1",
|
|
39
39
|
"c8": "8.0.1",
|
|
40
|
-
"eslint": "8.
|
|
40
|
+
"eslint": "8.54.0",
|
|
41
41
|
"react": "18.2.0",
|
|
42
42
|
"ts-node": "10.9.1",
|
|
43
43
|
"typescript": "5.2.2"
|