@midnight-ntwrk/wallet-sdk-utilities 1.0.0-beta.8 → 1.0.0

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/README.md ADDED
@@ -0,0 +1,90 @@
1
+ # @midnight-ntwrk/wallet-sdk-utilities
2
+
3
+ Domain-agnostic utilities for the Midnight Wallet SDK.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install @midnight-ntwrk/wallet-sdk-utilities
9
+ ```
10
+
11
+ ## Overview
12
+
13
+ This package provides common utility functions and types used throughout the Midnight Wallet SDK. It includes:
14
+
15
+ - Array operations
16
+ - Blob/binary data operations
17
+ - Date utilities
18
+ - Either/Result type operations
19
+ - Fluent API helpers
20
+ - Heterogeneous list types
21
+ - Ledger operations
22
+ - Observable utilities
23
+ - Polymorphic functions
24
+ - Record operations
25
+
26
+ ## Exports
27
+
28
+ ### Default Export
29
+
30
+ ```typescript
31
+ import {
32
+ ArrayOps, // Array manipulation utilities
33
+ BlobOps, // Binary data operations
34
+ DateOps, // Date handling utilities
35
+ EitherOps, // Either/Result type helpers
36
+ Fluent, // Fluent API patterns
37
+ HList, // Heterogeneous list types
38
+ LedgerOps, // Ledger-specific operations
39
+ ObservableOps, // RxJS Observable utilities
40
+ Poly, // Polymorphic function helpers
41
+ RecordOps, // Object/Record utilities
42
+ } from '@midnight-ntwrk/wallet-sdk-utilities';
43
+ ```
44
+
45
+ ### Networking Submodule (`/networking`)
46
+
47
+ Network-related utilities:
48
+
49
+ ```typescript
50
+ import { ... } from '@midnight-ntwrk/wallet-sdk-utilities/networking';
51
+ ```
52
+
53
+ ### Types Submodule (`/types`)
54
+
55
+ Common type definitions:
56
+
57
+ ```typescript
58
+ import { ... } from '@midnight-ntwrk/wallet-sdk-utilities/types';
59
+ ```
60
+
61
+ ### Testing Submodule (`/testing`)
62
+
63
+ Testing utilities and helpers:
64
+
65
+ ```typescript
66
+ import { ... } from '@midnight-ntwrk/wallet-sdk-utilities/testing';
67
+ ```
68
+
69
+ ## Usage Examples
70
+
71
+ ### Observable Operations
72
+
73
+ ```typescript
74
+ import { ObservableOps } from '@midnight-ntwrk/wallet-sdk-utilities';
75
+
76
+ // Convert Effect streams to RxJS Observables
77
+ const observable = ObservableOps.fromStream(effectStream);
78
+ ```
79
+
80
+ ### Array Operations
81
+
82
+ ```typescript
83
+ import { ArrayOps } from '@midnight-ntwrk/wallet-sdk-utilities';
84
+
85
+ // Various array manipulation utilities
86
+ ```
87
+
88
+ ## License
89
+
90
+ Apache-2.0
@@ -18,7 +18,7 @@ const startContainer = (container) => {
18
18
  return Effect.acquireRelease(Effect.promise(() => container.start()), (container) => Effect.promise(() => container.stop({ timeout: 5_000 })));
19
19
  };
20
20
  export const runNodeContainer = (adjustment = identity) => {
21
- const container = new GenericContainer('ghcr.io/midnight-ntwrk/midnight-node:0.18.0-rc.4')
21
+ const container = new GenericContainer('ghcr.io/midnight-ntwrk/midnight-node:0.20.0-rc.6')
22
22
  .withEnvironment({
23
23
  CFG_PRESET: 'dev',
24
24
  SIDECHAIN_BLOCK_BENEFICIARY: '04bcf7ad3be7a5c790460be82a713af570f22e0f801f6659ab8e84a52be6969e',
@@ -28,7 +28,7 @@ export const runNodeContainer = (adjustment = identity) => {
28
28
  return startContainer(adjustment(container));
29
29
  };
30
30
  export const runProofServerContainer = (adjustment = identity) => {
31
- const container = new GenericContainer('ghcr.io/midnight-ntwrk/proof-server:6.1.0-alpha.6')
31
+ const container = new GenericContainer('ghcr.io/midnight-ntwrk/proof-server:7.0.0')
32
32
  .withEnvironment({
33
33
  RUST_BACKTRACE: 'full',
34
34
  })
@@ -38,7 +38,7 @@ export const runProofServerContainer = (adjustment = identity) => {
38
38
  return startContainer(adjustment(container));
39
39
  };
40
40
  export const runTxGenerator = (config, adjustment = identity) => {
41
- const container = new GenericContainer('ghcr.io/midnight-ntwrk/midnight-node-toolkit:0.18.0-rc.4')
41
+ const container = new GenericContainer('ghcr.io/midnight-ntwrk/midnight-node-toolkit:0.20.0-rc.1')
42
42
  .withBindMounts([{ source: config.destPath, target: '/tmp', mode: 'rw' }])
43
43
  .withCommand([
44
44
  'generate-txs',
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@midnight-ntwrk/wallet-sdk-utilities",
3
3
  "description": "Domain-agnostic utilities for the wallet SDK - common operations and types",
4
- "version": "1.0.0-beta.8",
4
+ "version": "1.0.0",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
7
7
  "module": "./dist/index.js",
@@ -37,10 +37,10 @@
37
37
  }
38
38
  },
39
39
  "dependencies": {
40
- "effect": "^3.17.3",
40
+ "effect": "^3.19.14",
41
41
  "portfinder": "^1.0.37",
42
42
  "rxjs": "^7.5",
43
- "testcontainers": "^11.8.1"
43
+ "testcontainers": "^11.10.0"
44
44
  },
45
45
  "scripts": {
46
46
  "typecheck": "tsc -b ./tsconfig.json --noEmit",
@@ -56,9 +56,10 @@
56
56
  "devDependencies": {
57
57
  "eslint": "^9.37.0",
58
58
  "fast-check": "^4.2.0",
59
+ "prettier": "^3.7.0",
59
60
  "publint": "~0.3.14",
60
61
  "rimraf": "^6.0.1",
61
62
  "typescript": "^5.9.3",
62
- "vitest": "^3.2.4"
63
+ "vitest": "^4.0.16"
63
64
  }
64
65
  }