fortepiano 0.1.9 → 1.0.2
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 +30 -17
- package/{lib/Mock.d.ts → dist/cjs/index.d.ts} +1 -1
- package/{lib/Mock.js → dist/cjs/index.js} +31 -24
- package/dist/cjs/utils/Type.d.ts +2 -0
- package/{lib/Magma.js → dist/cjs/utils/Type.js} +4 -4
- package/dist/cjs/utils/function.d.ts +16 -0
- package/dist/cjs/utils/function.js +39 -0
- package/dist/cjs/utils/struct.d.ts +16 -0
- package/{lib → dist/cjs/utils}/struct.js +1 -7
- package/{Mock.d.ts → dist/esm/index.d.ts} +1 -1
- package/{esm/Mock.js → dist/esm/index.js} +13 -6
- package/dist/esm/utils/Type.d.ts +2 -0
- package/dist/esm/utils/Type.js +4 -0
- package/dist/esm/utils/function.d.ts +16 -0
- package/dist/esm/utils/function.js +33 -0
- package/dist/esm/utils/struct.d.ts +16 -0
- package/{esm → dist/esm/utils}/struct.js +0 -3
- package/package.json +23 -56
- package/Aggregate/package.json +0 -6
- package/Aggregate.d.ts +0 -4
- package/AsyncYield/package.json +0 -6
- package/AsyncYield.d.ts +0 -104
- package/Binary/package.json +0 -6
- package/Binary.d.ts +0 -5
- package/Buffer/package.json +0 -6
- package/Buffer.d.ts +0 -4
- package/CHANGELOG.md +0 -168
- package/CONTRIBUTING.md +0 -51
- package/Cache/package.json +0 -6
- package/Cache.d.ts +0 -18
- package/Console/package.json +0 -6
- package/Console.d.ts +0 -20
- package/Crypto/package.json +0 -6
- package/Crypto.d.ts +0 -4
- package/Date/package.json +0 -6
- package/Date.d.ts +0 -4
- package/Eq/package.json +0 -6
- package/Eq.d.ts +0 -4
- package/Error/package.json +0 -6
- package/Error.d.ts +0 -13
- package/GeneratorL/package.json +0 -6
- package/GeneratorL.d.ts +0 -714
- package/Has/package.json +0 -6
- package/Has.d.ts +0 -16
- package/Http/package.json +0 -6
- package/Http.d.ts +0 -59
- package/Log/package.json +0 -6
- package/Log.d.ts +0 -4
- package/Magma/package.json +0 -6
- package/Magma.d.ts +0 -2
- package/Matrix/package.json +0 -6
- package/Matrix.d.ts +0 -9
- package/Mock/package.json +0 -6
- package/Option/package.json +0 -6
- package/Option.d.ts +0 -2
- package/Random/package.json +0 -6
- package/Random.d.ts +0 -7
- package/Reader/package.json +0 -6
- package/Reader.d.ts +0 -4
- package/ReaderEither/package.json +0 -6
- package/ReaderEither.d.ts +0 -9
- package/ReaderTask/package.json +0 -6
- package/ReaderTask.d.ts +0 -8
- package/ReaderTaskEither/package.json +0 -6
- package/ReaderTaskEither.d.ts +0 -66
- package/ReadonlyArray/package.json +0 -6
- package/ReadonlyArray.d.ts +0 -75
- package/ReadonlyRecord/package.json +0 -6
- package/ReadonlyRecord.d.ts +0 -5
- package/ReadonlyTuple/package.json +0 -6
- package/ReadonlyTuple.d.ts +0 -14
- package/Storage/package.json +0 -6
- package/Storage.d.ts +0 -14
- package/Stream/package.json +0 -6
- package/Stream.d.ts +0 -4
- package/TaskEither/package.json +0 -6
- package/TaskEither.d.ts +0 -2
- package/Type/package.json +0 -6
- package/Type.d.ts +0 -13
- package/Validation/package.json +0 -6
- package/Validation.d.ts +0 -4
- package/Yield/package.json +0 -6
- package/Yield.d.ts +0 -210
- package/cache/Memcached/package.json +0 -6
- package/cache/Memcached.d.ts +0 -4
- package/cache/Memory/package.json +0 -6
- package/cache/Memory.d.ts +0 -2
- package/cache/Redis/package.json +0 -6
- package/cache/Redis.d.ts +0 -4
- package/cache/Storage/package.json +0 -6
- package/cache/Storage.d.ts +0 -4
- package/esm/Aggregate.js +0 -1
- package/esm/AsyncYield.js +0 -411
- package/esm/Binary.js +0 -12
- package/esm/Buffer.js +0 -22
- package/esm/Cache.js +0 -25
- package/esm/Console.js +0 -20
- package/esm/Crypto.js +0 -12
- package/esm/Date.js +0 -5
- package/esm/Eq.js +0 -6
- package/esm/Error.js +0 -45
- package/esm/GeneratorL.js +0 -802
- package/esm/Has.js +0 -5
- package/esm/Http.js +0 -138
- package/esm/Log.js +0 -2
- package/esm/Magma.js +0 -3
- package/esm/Matrix.js +0 -12
- package/esm/Option.js +0 -3
- package/esm/Random.js +0 -3
- package/esm/Reader.js +0 -6
- package/esm/ReaderEither.js +0 -7
- package/esm/ReaderTask.js +0 -8
- package/esm/ReaderTaskEither.js +0 -58
- package/esm/ReadonlyArray.js +0 -44
- package/esm/ReadonlyRecord.js +0 -5
- package/esm/ReadonlyTuple.js +0 -10
- package/esm/Storage.js +0 -34
- package/esm/Stream.js +0 -9
- package/esm/TaskEither.js +0 -9
- package/esm/Type.js +0 -29
- package/esm/Validation.js +0 -6
- package/esm/Yield.js +0 -401
- package/esm/cache/Memcached.js +0 -27
- package/esm/cache/Memory.js +0 -43
- package/esm/cache/Redis.js +0 -35
- package/esm/cache/Storage.js +0 -40
- package/esm/function.js +0 -92
- package/esm/http/Axios.js +0 -36
- package/esm/http/Fetch.js +0 -48
- package/esm/http/Got.js +0 -40
- package/esm/http/Mock.js +0 -30
- package/esm/index.js +0 -39
- package/esm/log/Void.js +0 -3
- package/esm/number.js +0 -5
- package/esm/storage/Flydrive.js +0 -44
- package/esm/storage/Fs.js +0 -27
- package/esm/string.js +0 -9
- package/function/package.json +0 -6
- package/function.d.ts +0 -52
- package/http/Axios/package.json +0 -6
- package/http/Axios.d.ts +0 -3
- package/http/Fetch/package.json +0 -6
- package/http/Fetch.d.ts +0 -2
- package/http/Got/package.json +0 -6
- package/http/Got.d.ts +0 -6
- package/http/Mock/package.json +0 -6
- package/http/Mock.d.ts +0 -2
- package/index.d.ts +0 -55
- package/lib/Aggregate.d.ts +0 -4
- package/lib/Aggregate.js +0 -2
- package/lib/AsyncYield.d.ts +0 -104
- package/lib/AsyncYield.js +0 -461
- package/lib/Binary.d.ts +0 -5
- package/lib/Binary.js +0 -15
- package/lib/Buffer.d.ts +0 -4
- package/lib/Buffer.js +0 -49
- package/lib/Cache.d.ts +0 -18
- package/lib/Cache.js +0 -54
- package/lib/Console.d.ts +0 -20
- package/lib/Console.js +0 -25
- package/lib/Crypto.d.ts +0 -4
- package/lib/Crypto.js +0 -43
- package/lib/Date.d.ts +0 -4
- package/lib/Date.js +0 -34
- package/lib/Eq.d.ts +0 -4
- package/lib/Eq.js +0 -33
- package/lib/Error.d.ts +0 -13
- package/lib/Error.js +0 -74
- package/lib/GeneratorL.d.ts +0 -714
- package/lib/GeneratorL.js +0 -905
- package/lib/Has.d.ts +0 -16
- package/lib/Has.js +0 -13
- package/lib/Http.d.ts +0 -59
- package/lib/Http.js +0 -172
- package/lib/Log.d.ts +0 -4
- package/lib/Log.js +0 -5
- package/lib/Magma.d.ts +0 -2
- package/lib/Matrix.d.ts +0 -9
- package/lib/Matrix.js +0 -40
- package/lib/Option.d.ts +0 -2
- package/lib/Option.js +0 -30
- package/lib/Random.d.ts +0 -7
- package/lib/Random.js +0 -7
- package/lib/Reader.d.ts +0 -4
- package/lib/Reader.js +0 -35
- package/lib/ReaderEither.d.ts +0 -9
- package/lib/ReaderEither.js +0 -38
- package/lib/ReaderTask.d.ts +0 -8
- package/lib/ReaderTask.js +0 -39
- package/lib/ReaderTaskEither.d.ts +0 -66
- package/lib/ReaderTaskEither.js +0 -138
- package/lib/ReadonlyArray.d.ts +0 -75
- package/lib/ReadonlyArray.js +0 -74
- package/lib/ReadonlyRecord.d.ts +0 -5
- package/lib/ReadonlyRecord.js +0 -34
- package/lib/ReadonlyTuple.d.ts +0 -14
- package/lib/ReadonlyTuple.js +0 -38
- package/lib/Storage.d.ts +0 -14
- package/lib/Storage.js +0 -61
- package/lib/Stream.d.ts +0 -4
- package/lib/Stream.js +0 -35
- package/lib/TaskEither.d.ts +0 -2
- package/lib/TaskEither.js +0 -36
- package/lib/Type.d.ts +0 -13
- package/lib/Type.js +0 -61
- package/lib/Validation.d.ts +0 -4
- package/lib/Validation.js +0 -34
- package/lib/Yield.d.ts +0 -210
- package/lib/Yield.js +0 -504
- package/lib/cache/Memcached.d.ts +0 -4
- package/lib/cache/Memcached.js +0 -54
- package/lib/cache/Memory.d.ts +0 -2
- package/lib/cache/Memory.js +0 -70
- package/lib/cache/Redis.d.ts +0 -4
- package/lib/cache/Redis.js +0 -62
- package/lib/cache/Storage.d.ts +0 -4
- package/lib/cache/Storage.js +0 -66
- package/lib/function.d.ts +0 -52
- package/lib/function.js +0 -101
- package/lib/http/Axios.d.ts +0 -3
- package/lib/http/Axios.js +0 -63
- package/lib/http/Fetch.d.ts +0 -2
- package/lib/http/Fetch.js +0 -75
- package/lib/http/Got.d.ts +0 -6
- package/lib/http/Got.js +0 -67
- package/lib/http/Mock.d.ts +0 -2
- package/lib/http/Mock.js +0 -56
- package/lib/index.d.ts +0 -55
- package/lib/index.js +0 -98
- package/lib/log/Void.d.ts +0 -3
- package/lib/log/Void.js +0 -6
- package/lib/number.d.ts +0 -3
- package/lib/number.js +0 -8
- package/lib/storage/Flydrive.d.ts +0 -4
- package/lib/storage/Flydrive.js +0 -71
- package/lib/storage/Fs.d.ts +0 -3
- package/lib/storage/Fs.js +0 -57
- package/lib/string.d.ts +0 -8
- package/lib/string.js +0 -43
- package/lib/struct.d.ts +0 -13
- package/log/Void/package.json +0 -6
- package/log/Void.d.ts +0 -3
- package/number/package.json +0 -6
- package/number.d.ts +0 -3
- package/storage/Flydrive/package.json +0 -6
- package/storage/Flydrive.d.ts +0 -4
- package/storage/Fs/package.json +0 -6
- package/storage/Fs.d.ts +0 -3
- package/string/package.json +0 -6
- package/string.d.ts +0 -8
- package/struct/package.json +0 -6
- package/struct.d.ts +0 -13
package/README.md
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<img src="./logo.png" width=150px" height="auto"/>
|
|
3
|
+
</p>
|
|
4
|
+
|
|
1
5
|
# fortepiano [ˌfɔrteˈpjaːno]
|
|
2
6
|
|
|
3
|
-
_Playing actual music over `fp-ts` notes_
|
|
7
|
+
_Playing actual music over `fp-ts` notes_ 🎶
|
|
4
8
|
|
|
5
9
|
[](https://github.com/facile-it/fortepiano/actions)
|
|
6
10
|
[](https://app.codecov.io/gh/facile-it/fortepiano)
|
|
@@ -9,36 +13,45 @@ _Playing actual music over `fp-ts` notes_
|
|
|
9
13
|
|
|
10
14
|
## Description
|
|
11
15
|
|
|
12
|
-
|
|
16
|
+
Fortepiano is a mocking library for TypeScript. It promotes immutability, composability and purity, making it ideal for projects that embrace functional programming principles.
|
|
13
17
|
|
|
14
18
|
## Getting Started
|
|
15
19
|
|
|
16
|
-
`fortepiano` stands on the shoulders of the giant `fp-ts`. As such, a good understanding of its [concepts](https://gcanti.github.io/fp-ts/) is suggested.
|
|
17
|
-
|
|
18
20
|
### Installation
|
|
19
21
|
|
|
20
|
-
|
|
22
|
+
To install the stable version:
|
|
21
23
|
|
|
22
|
-
```
|
|
23
|
-
npm install fortepiano
|
|
24
|
+
```bash
|
|
25
|
+
npm install fortepiano
|
|
24
26
|
```
|
|
25
27
|
|
|
26
|
-
|
|
28
|
+
or using yarn:
|
|
27
29
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
- [`@slynova/flydrive`](https://www.npmjs.com/package/@slynova/flydrive) (`storage/Flydrive`)
|
|
30
|
+
```bash
|
|
31
|
+
yarn add fortepiano
|
|
32
|
+
```
|
|
32
33
|
|
|
33
34
|
### Usage
|
|
34
35
|
|
|
35
|
-
|
|
36
|
+
Fortepiano uses a functional API to create and configure mocks, encouraging pure function usage and immutable mock objects.
|
|
37
|
+
|
|
38
|
+
Here's an example:
|
|
36
39
|
|
|
37
40
|
```typescript
|
|
38
|
-
import { $
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
41
|
+
import { $mock } from 'fortepiano'
|
|
42
|
+
|
|
43
|
+
interface User {
|
|
44
|
+
firstName: string
|
|
45
|
+
lastName: string
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export const UserMock = (): $mock.Mock<User> =>
|
|
49
|
+
$mock.struct({
|
|
50
|
+
firstName: $mock.string,
|
|
51
|
+
lastName: $mock.string,
|
|
52
|
+
})
|
|
53
|
+
|
|
54
|
+
console.log(UserMock()()()) // Output: { firstName: 'randomString', lastName: 'randomString' }
|
|
42
55
|
```
|
|
43
56
|
|
|
44
57
|
## Contributing
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { PartialDeep } from '.';
|
|
2
1
|
import * as Appli from 'fp-ts/Applicative';
|
|
3
2
|
import * as _Apply from 'fp-ts/Apply';
|
|
4
3
|
import * as C from 'fp-ts/Chain';
|
|
@@ -10,6 +9,7 @@ import * as MIO from 'fp-ts/MonadIO';
|
|
|
10
9
|
import * as P from 'fp-ts/Pointed';
|
|
11
10
|
import * as RNEA from 'fp-ts/ReadonlyNonEmptyArray';
|
|
12
11
|
import * as RR from 'fp-ts/ReadonlyRecord';
|
|
12
|
+
import { PartialDeep } from './utils/struct';
|
|
13
13
|
export declare const URI = "Mock";
|
|
14
14
|
export declare type URI = typeof URI;
|
|
15
15
|
declare module 'fp-ts/HKT' {
|
|
@@ -24,14 +24,10 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
26
|
exports.null = exports.undefined = exports.void = exports.readonlyRecord = exports.readonlyNonEmptyArray = exports.readonlyArray = exports.union = exports.partial = exports.struct = exports.tuple = exports.nullable = exports.unknown = exports.literal = exports.string = exports.number = exports.integer = exports.float = exports.boolean = exports.MonadIO = exports.chainFirstIOK = exports.chainIOK = exports.fromIOK = exports.fromIO = exports.FromIO = exports.Monad = exports.bind = exports.chainFirst = exports.chain = exports.Chain = exports.Applicative = exports.apS = exports.apSecond = exports.apFirst = exports.ap = exports.Apply = exports.Do = exports.of = exports.Pointed = exports.bindTo = exports.flap = exports.map = exports.Functor = exports.URI = void 0;
|
|
27
|
-
const function_1 = require("./function");
|
|
28
|
-
const $St = __importStar(require("./struct"));
|
|
29
|
-
const $t = __importStar(require("./Type"));
|
|
30
|
-
const $Y = __importStar(require("./Yield"));
|
|
31
27
|
const _Apply = __importStar(require("fp-ts/Apply"));
|
|
32
28
|
const C = __importStar(require("fp-ts/Chain"));
|
|
33
29
|
const FIO = __importStar(require("fp-ts/FromIO"));
|
|
34
|
-
const
|
|
30
|
+
const function_1 = require("fp-ts/function");
|
|
35
31
|
const F = __importStar(require("fp-ts/Functor"));
|
|
36
32
|
const IO = __importStar(require("fp-ts/IO"));
|
|
37
33
|
const N = __importStar(require("fp-ts/number"));
|
|
@@ -44,59 +40,62 @@ const RNEA = __importStar(require("fp-ts/ReadonlyNonEmptyArray"));
|
|
|
44
40
|
const RR = __importStar(require("fp-ts/ReadonlyRecord"));
|
|
45
41
|
const Se = __importStar(require("fp-ts/Semigroup"));
|
|
46
42
|
const t = __importStar(require("io-ts"));
|
|
43
|
+
const function_2 = require("./utils/function");
|
|
44
|
+
const $St = __importStar(require("./utils/struct"));
|
|
45
|
+
const $t = __importStar(require("./utils/Type"));
|
|
47
46
|
exports.URI = 'Mock';
|
|
48
47
|
exports.Functor = {
|
|
49
48
|
URI: exports.URI,
|
|
50
|
-
map: (fa, f) => (0,
|
|
49
|
+
map: (fa, f) => (0, function_1.pipe)(fa(), IO.map(f), exports.FromIO.fromIO),
|
|
51
50
|
};
|
|
52
|
-
exports.map = (0,
|
|
51
|
+
exports.map = (0, function_2.curry)((0, function_1.flip)(exports.Functor.map));
|
|
53
52
|
exports.flap = F.flap(exports.Functor);
|
|
54
53
|
exports.bindTo = F.bindTo(exports.Functor);
|
|
55
54
|
exports.Pointed = {
|
|
56
55
|
URI: exports.URI,
|
|
57
|
-
of: (a) => (...as) => (0,
|
|
58
|
-
? (0,
|
|
56
|
+
of: (a) => (...as) => (0, function_1.pipe)(as, RNEA.fromReadonlyArray, Op.traverse(IO.Applicative)(R.randomElem), IO.map(Op.match(() => a, (_a) => $t.struct.is(a) && $t.struct.is(_a)
|
|
57
|
+
? (0, function_1.pipe)(_a, $St.filterDeep(Pr.not(t.undefined.is)), (_a) => $St.patch(_a)(a))
|
|
59
58
|
: _a))),
|
|
60
59
|
};
|
|
61
60
|
exports.of = exports.Pointed.of;
|
|
62
61
|
exports.Do = exports.Pointed.of({});
|
|
63
|
-
exports.Apply = Object.assign(Object.assign({}, exports.Functor), { ap: (fab, fa) => exports.Chain.chain(fab, (0,
|
|
64
|
-
exports.ap = (0,
|
|
62
|
+
exports.Apply = Object.assign(Object.assign({}, exports.Functor), { ap: (fab, fa) => exports.Chain.chain(fab, (0, function_2.curry)(exports.Functor.map)(fa)) });
|
|
63
|
+
exports.ap = (0, function_2.curry)((0, function_1.flip)(exports.Apply.ap));
|
|
65
64
|
exports.apFirst = _Apply.apFirst(exports.Apply);
|
|
66
65
|
exports.apSecond = _Apply.apSecond(exports.Apply);
|
|
67
66
|
exports.apS = _Apply.apS(exports.Apply);
|
|
68
67
|
exports.Applicative = Object.assign(Object.assign({}, exports.Pointed), exports.Apply);
|
|
69
68
|
exports.Chain = Object.assign(Object.assign({}, exports.Apply), { chain: (fa, f) => exports.Functor.map(exports.Functor.map(fa, f), (fb) => fb()()) });
|
|
70
|
-
exports.chain = (0,
|
|
69
|
+
exports.chain = (0, function_2.curry)((0, function_1.flip)(exports.Chain.chain));
|
|
71
70
|
exports.chainFirst = C.chainFirst(exports.Chain);
|
|
72
71
|
exports.bind = C.bind(exports.Chain);
|
|
73
72
|
exports.Monad = Object.assign(Object.assign({}, exports.Applicative), exports.Chain);
|
|
74
73
|
exports.FromIO = {
|
|
75
74
|
URI: exports.URI,
|
|
76
|
-
fromIO: (fa) => (...as) => (0,
|
|
75
|
+
fromIO: (fa) => (...as) => (0, function_1.pipe)(fa, IO.chain((a) => exports.Pointed.of(a)(...as))),
|
|
77
76
|
};
|
|
78
77
|
exports.fromIO = exports.FromIO.fromIO;
|
|
79
78
|
exports.fromIOK = FIO.fromIOK(exports.FromIO);
|
|
80
79
|
exports.chainIOK = FIO.chainIOK(exports.FromIO, exports.Chain);
|
|
81
80
|
exports.chainFirstIOK = FIO.chainFirstIOK(exports.FromIO, exports.Chain);
|
|
82
81
|
exports.MonadIO = Object.assign(Object.assign({}, exports.Monad), exports.FromIO);
|
|
83
|
-
const _void = () =>
|
|
82
|
+
const _void = () => function_1.constVoid;
|
|
84
83
|
exports.void = _void;
|
|
85
|
-
const _undefined = () =>
|
|
84
|
+
const _undefined = () => function_1.constUndefined;
|
|
86
85
|
exports.undefined = _undefined;
|
|
87
|
-
const _null = () =>
|
|
86
|
+
const _null = () => function_1.constNull;
|
|
88
87
|
exports.null = _null;
|
|
89
88
|
exports.boolean = (0, exports.fromIO)(R.randomBool);
|
|
90
|
-
const float = (min = Number.MIN_SAFE_INTEGER * 1e-6, max = Number.MAX_SAFE_INTEGER * 1e-6) => (...as) => (0,
|
|
89
|
+
const float = (min = Number.MIN_SAFE_INTEGER * 1e-6, max = Number.MAX_SAFE_INTEGER * 1e-6) => (...as) => (0, function_1.pipe)((0, exports.fromIO)(R.randomRange(min, Math.max(min + Number.EPSILON, max)))(...as), IO.map(Or.clamp(N.Ord)(min, Math.max(min + Number.EPSILON, max - Number.EPSILON))));
|
|
91
90
|
exports.float = float;
|
|
92
|
-
const integer = (min = Number.MIN_SAFE_INTEGER * 1e-6, max = Number.MAX_SAFE_INTEGER * 1e-6) => (...as) => (0,
|
|
91
|
+
const integer = (min = Number.MIN_SAFE_INTEGER * 1e-6, max = Number.MAX_SAFE_INTEGER * 1e-6) => (...as) => (0, function_1.pipe)((0, exports.float)(min, max)(...as), IO.map(Math.floor));
|
|
93
92
|
exports.integer = integer;
|
|
94
|
-
const number = (min = Number.MIN_SAFE_INTEGER * 1e-6, max = Number.MAX_SAFE_INTEGER * 1e-6) => (...as) => (0,
|
|
93
|
+
const number = (min = Number.MIN_SAFE_INTEGER * 1e-6, max = Number.MAX_SAFE_INTEGER * 1e-6) => (...as) => (0, function_1.pipe)(union((0, exports.float)(min, max), (0, exports.integer)(min, max))(...as), IO.map(Or.clamp(N.Ord)(min, Math.max(min + Number.EPSILON, max - Number.EPSILON))));
|
|
95
94
|
exports.number = number;
|
|
96
95
|
exports.string = (0, exports.fromIO)(() => Math.random().toString(36).split('.')[1]);
|
|
97
96
|
const literal = (a) => (0, exports.of)(a);
|
|
98
97
|
exports.literal = literal;
|
|
99
|
-
const unknown = (depth = 10) => (0,
|
|
98
|
+
const unknown = (depth = 10) => (0, function_2.recurse)((_unknown, _depth) => (_depth < depth
|
|
100
99
|
? union(_undefined, _null, exports.boolean, (0, exports.number)(), exports.string, (0, exports.readonlyArray)(_unknown), (0, exports.readonlyRecord)(exports.string, _unknown))
|
|
101
100
|
: union(_undefined, _null, exports.boolean, (0, exports.number)(), exports.string)));
|
|
102
101
|
exports.unknown = unknown;
|
|
@@ -104,15 +103,23 @@ const nullable = (M) => union(M, _undefined);
|
|
|
104
103
|
exports.nullable = nullable;
|
|
105
104
|
exports.tuple = _Apply.sequenceT(exports.Apply);
|
|
106
105
|
exports.struct = _Apply.sequenceS(exports.Apply);
|
|
107
|
-
const partial = (Ms) => (0,
|
|
106
|
+
const partial = (Ms) => (0, function_1.pipe)(Ms, RR.map(exports.nullable), exports.struct);
|
|
108
107
|
exports.partial = partial;
|
|
109
108
|
function union(...Ms) {
|
|
110
|
-
return (0,
|
|
109
|
+
return (0, function_1.pipe)(Ms, R.randomElem, IO.chain(function_2.run), exports.fromIO);
|
|
111
110
|
}
|
|
112
111
|
exports.union = union;
|
|
113
|
-
const readonlyArray = (M, min = 0, max = 10) =>
|
|
112
|
+
const readonlyArray = (M, min = 0, max = 10) => {
|
|
113
|
+
return (as) => () => {
|
|
114
|
+
if (as !== undefined) {
|
|
115
|
+
return as;
|
|
116
|
+
}
|
|
117
|
+
const rndNum = R.randomInt(Math.max(0, min), Math.max(0, min, max))();
|
|
118
|
+
return Array.from({ length: rndNum }, M());
|
|
119
|
+
};
|
|
120
|
+
};
|
|
114
121
|
exports.readonlyArray = readonlyArray;
|
|
115
122
|
const readonlyNonEmptyArray = (M, min = 1, max = 10) => (0, exports.readonlyArray)(M, Math.max(1, min), Math.max(1, min, max));
|
|
116
123
|
exports.readonlyNonEmptyArray = readonlyNonEmptyArray;
|
|
117
|
-
const readonlyRecord = (KM, TM, min = 0, max = 10) => (0,
|
|
124
|
+
const readonlyRecord = (KM, TM, min = 0, max = 10) => (0, function_1.pipe)((0, exports.readonlyArray)((0, exports.tuple)(KM, TM), Math.max(0, min), Math.max(0, min, max))(), IO.map((entries) => RR.fromFoldable(Se.last(), RA.Foldable)(entries)), exports.fromIO);
|
|
118
125
|
exports.readonlyRecord = readonlyRecord;
|
|
@@ -23,8 +23,8 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.
|
|
26
|
+
exports.struct = void 0;
|
|
27
27
|
const function_1 = require("fp-ts/function");
|
|
28
|
-
const
|
|
29
|
-
const
|
|
30
|
-
exports.
|
|
28
|
+
const t = __importStar(require("io-ts"));
|
|
29
|
+
const isStruct = (u) => 'object' === typeof u && null !== u && !Array.isArray(u);
|
|
30
|
+
exports.struct = new t.Type('struct', isStruct, (u, c) => (isStruct(u) ? t.success(u) : t.failure(u, c)), function_1.identity);
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Lazy } from 'fp-ts/function';
|
|
2
|
+
export declare const run: <A>(f: Lazy<A>) => A;
|
|
3
|
+
export declare function curry<A, B, C>(f: (a: A, b: B) => C): (a: A) => (b: B) => C;
|
|
4
|
+
export declare function curry<A, B, C, D>(f: (a: A, b: B, c: C) => D): (a: A) => (b: B) => (c: C) => D;
|
|
5
|
+
/**
|
|
6
|
+
* @example
|
|
7
|
+
* const pi = (max: number) => (): ((n?: number) => number) =>
|
|
8
|
+
* recurse((self, depth) => (n = 1) =>
|
|
9
|
+
* 4 / n + (depth < max ? self(-1 * n + (n < 0 ? 2 : -2)) : 0)
|
|
10
|
+
* )
|
|
11
|
+
* const pi100 = pi(100)()()
|
|
12
|
+
*
|
|
13
|
+
* expect(pi100).toBeGreaterThan(3.15)
|
|
14
|
+
* expect(pi100).toBeLessThan(3.16)
|
|
15
|
+
*/
|
|
16
|
+
export declare const recurse: <A extends (...args: any) => any>(f: (self: A, depth: number) => A, cache?: boolean) => A;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.recurse = exports.curry = exports.run = void 0;
|
|
4
|
+
const run = (f) => f();
|
|
5
|
+
exports.run = run;
|
|
6
|
+
function curry(f) {
|
|
7
|
+
return function curried(...head) {
|
|
8
|
+
return head.length >= f.length
|
|
9
|
+
? f(...head)
|
|
10
|
+
: (...rest) => curried(...head.concat(rest));
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
exports.curry = curry;
|
|
14
|
+
/**
|
|
15
|
+
* @example
|
|
16
|
+
* const pi = (max: number) => (): ((n?: number) => number) =>
|
|
17
|
+
* recurse((self, depth) => (n = 1) =>
|
|
18
|
+
* 4 / n + (depth < max ? self(-1 * n + (n < 0 ? 2 : -2)) : 0)
|
|
19
|
+
* )
|
|
20
|
+
* const pi100 = pi(100)()()
|
|
21
|
+
*
|
|
22
|
+
* expect(pi100).toBeGreaterThan(3.15)
|
|
23
|
+
* expect(pi100).toBeLessThan(3.16)
|
|
24
|
+
*/
|
|
25
|
+
const recurse = (f, cache = false) => {
|
|
26
|
+
let depth = 0;
|
|
27
|
+
let _cache = null;
|
|
28
|
+
const run = !cache
|
|
29
|
+
? f
|
|
30
|
+
: (_self, _depth) => {
|
|
31
|
+
if (!_cache) {
|
|
32
|
+
_cache = f(_self, _depth);
|
|
33
|
+
}
|
|
34
|
+
return _cache;
|
|
35
|
+
};
|
|
36
|
+
const self = ((...args) => run(self, depth++)(...args));
|
|
37
|
+
return self;
|
|
38
|
+
};
|
|
39
|
+
exports.recurse = recurse;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Predicate } from 'fp-ts/Predicate';
|
|
2
|
+
export declare type Struct = object;
|
|
3
|
+
export declare type PartialDeep<A> = A extends {
|
|
4
|
+
readonly [x: string]: unknown;
|
|
5
|
+
} ? Partial<{
|
|
6
|
+
readonly [K in keyof A]: PartialDeep<A[K]>;
|
|
7
|
+
}> : A;
|
|
8
|
+
declare type IntersectionDeep<A, B> = A extends {
|
|
9
|
+
readonly [x: string]: unknown;
|
|
10
|
+
} ? A & {
|
|
11
|
+
readonly [K in keyof B]: IntersectionDeep<K extends keyof A ? A[K] : unknown, B[K]>;
|
|
12
|
+
} : B;
|
|
13
|
+
export declare const toReadonlyArray: <A extends object>(a: A) => readonly (readonly [keyof A, A[keyof A]])[];
|
|
14
|
+
export declare const filterDeep: <A extends object>(f: Predicate<unknown>) => (a: A) => PartialDeep<A>;
|
|
15
|
+
export declare const patch: <A extends object, B extends PartialDeep<A> & object>(b: B) => (a: A) => IntersectionDeep<A, B>;
|
|
16
|
+
export {};
|
|
@@ -23,7 +23,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
|
|
|
23
23
|
return result;
|
|
24
24
|
};
|
|
25
25
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.patch = exports.filterDeep = exports.
|
|
26
|
+
exports.patch = exports.filterDeep = exports.toReadonlyArray = void 0;
|
|
27
27
|
const function_1 = require("fp-ts/function");
|
|
28
28
|
const RA = __importStar(require("fp-ts/ReadonlyArray"));
|
|
29
29
|
const RR = __importStar(require("fp-ts/ReadonlyRecord"));
|
|
@@ -32,12 +32,6 @@ const function_2 = require("./function");
|
|
|
32
32
|
const $t = __importStar(require("./Type"));
|
|
33
33
|
const toReadonlyArray = (a) => RR.toReadonlyArray(a);
|
|
34
34
|
exports.toReadonlyArray = toReadonlyArray;
|
|
35
|
-
const lookup = (k) => (s) => s[k];
|
|
36
|
-
exports.lookup = lookup;
|
|
37
|
-
const modifyAt = (k, f) => (s) => (Object.assign(Object.assign({}, s), { [k]: f(s[k]) }));
|
|
38
|
-
exports.modifyAt = modifyAt;
|
|
39
|
-
const updateAt = (k, a) => (0, exports.modifyAt)(k, () => a);
|
|
40
|
-
exports.updateAt = updateAt;
|
|
41
35
|
const filterDeep = (f) => (a) => (0, function_1.pipe)(a, exports.toReadonlyArray, RA.filter(([_, value]) => f(value)), RA.map(([key, value]) => $t.struct.is(value)
|
|
42
36
|
? [
|
|
43
37
|
key,
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { PartialDeep } from '.';
|
|
2
1
|
import * as Appli from 'fp-ts/Applicative';
|
|
3
2
|
import * as _Apply from 'fp-ts/Apply';
|
|
4
3
|
import * as C from 'fp-ts/Chain';
|
|
@@ -10,6 +9,7 @@ import * as MIO from 'fp-ts/MonadIO';
|
|
|
10
9
|
import * as P from 'fp-ts/Pointed';
|
|
11
10
|
import * as RNEA from 'fp-ts/ReadonlyNonEmptyArray';
|
|
12
11
|
import * as RR from 'fp-ts/ReadonlyRecord';
|
|
12
|
+
import { PartialDeep } from './utils/struct';
|
|
13
13
|
export declare const URI = "Mock";
|
|
14
14
|
export declare type URI = typeof URI;
|
|
15
15
|
declare module 'fp-ts/HKT' {
|
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
import { curry, recurse, run } from './function';
|
|
2
|
-
import * as $St from './struct';
|
|
3
|
-
import * as $t from './Type';
|
|
4
|
-
import * as $Y from './Yield';
|
|
5
1
|
import * as _Apply from 'fp-ts/Apply';
|
|
6
2
|
import * as C from 'fp-ts/Chain';
|
|
7
3
|
import * as FIO from 'fp-ts/FromIO';
|
|
@@ -18,6 +14,9 @@ import * as RNEA from 'fp-ts/ReadonlyNonEmptyArray';
|
|
|
18
14
|
import * as RR from 'fp-ts/ReadonlyRecord';
|
|
19
15
|
import * as Se from 'fp-ts/Semigroup';
|
|
20
16
|
import * as t from 'io-ts';
|
|
17
|
+
import { curry, recurse, run } from './utils/function';
|
|
18
|
+
import * as $St from './utils/struct';
|
|
19
|
+
import * as $t from './utils/Type';
|
|
21
20
|
export const URI = 'Mock';
|
|
22
21
|
export const Functor = {
|
|
23
22
|
URI,
|
|
@@ -73,7 +72,15 @@ export const partial = (Ms) => pipe(Ms, RR.map(nullable), struct);
|
|
|
73
72
|
export function union(...Ms) {
|
|
74
73
|
return pipe(Ms, R.randomElem, IO.chain(run), fromIO);
|
|
75
74
|
}
|
|
76
|
-
export const readonlyArray = (M, min = 0, max = 10) =>
|
|
75
|
+
export const readonlyArray = (M, min = 0, max = 10) => {
|
|
76
|
+
return (as) => () => {
|
|
77
|
+
if (as !== undefined) {
|
|
78
|
+
return as;
|
|
79
|
+
}
|
|
80
|
+
const rndNum = R.randomInt(Math.max(0, min), Math.max(0, min, max))();
|
|
81
|
+
return Array.from({ length: rndNum }, M());
|
|
82
|
+
};
|
|
83
|
+
};
|
|
77
84
|
export const readonlyNonEmptyArray = (M, min = 1, max = 10) => readonlyArray(M, Math.max(1, min), Math.max(1, min, max));
|
|
78
|
-
export const readonlyRecord = (KM, TM, min = 0, max = 10) => pipe(readonlyArray(tuple(KM, TM), Math.max(0, min), Math.max(0, min, max))(), IO.map(RR.fromFoldable(Se.last(), RA.Foldable)), fromIO);
|
|
85
|
+
export const readonlyRecord = (KM, TM, min = 0, max = 10) => pipe(readonlyArray(tuple(KM, TM), Math.max(0, min), Math.max(0, min, max))(), IO.map((entries) => RR.fromFoldable(Se.last(), RA.Foldable)(entries)), fromIO);
|
|
79
86
|
export { _void as void, _undefined as undefined, _null as null };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { identity } from 'fp-ts/function';
|
|
2
|
+
import * as t from 'io-ts';
|
|
3
|
+
const isStruct = (u) => 'object' === typeof u && null !== u && !Array.isArray(u);
|
|
4
|
+
export const struct = new t.Type('struct', isStruct, (u, c) => (isStruct(u) ? t.success(u) : t.failure(u, c)), identity);
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Lazy } from 'fp-ts/function';
|
|
2
|
+
export declare const run: <A>(f: Lazy<A>) => A;
|
|
3
|
+
export declare function curry<A, B, C>(f: (a: A, b: B) => C): (a: A) => (b: B) => C;
|
|
4
|
+
export declare function curry<A, B, C, D>(f: (a: A, b: B, c: C) => D): (a: A) => (b: B) => (c: C) => D;
|
|
5
|
+
/**
|
|
6
|
+
* @example
|
|
7
|
+
* const pi = (max: number) => (): ((n?: number) => number) =>
|
|
8
|
+
* recurse((self, depth) => (n = 1) =>
|
|
9
|
+
* 4 / n + (depth < max ? self(-1 * n + (n < 0 ? 2 : -2)) : 0)
|
|
10
|
+
* )
|
|
11
|
+
* const pi100 = pi(100)()()
|
|
12
|
+
*
|
|
13
|
+
* expect(pi100).toBeGreaterThan(3.15)
|
|
14
|
+
* expect(pi100).toBeLessThan(3.16)
|
|
15
|
+
*/
|
|
16
|
+
export declare const recurse: <A extends (...args: any) => any>(f: (self: A, depth: number) => A, cache?: boolean) => A;
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
export const run = (f) => f();
|
|
2
|
+
export function curry(f) {
|
|
3
|
+
return function curried(...head) {
|
|
4
|
+
return head.length >= f.length
|
|
5
|
+
? f(...head)
|
|
6
|
+
: (...rest) => curried(...head.concat(rest));
|
|
7
|
+
};
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* @example
|
|
11
|
+
* const pi = (max: number) => (): ((n?: number) => number) =>
|
|
12
|
+
* recurse((self, depth) => (n = 1) =>
|
|
13
|
+
* 4 / n + (depth < max ? self(-1 * n + (n < 0 ? 2 : -2)) : 0)
|
|
14
|
+
* )
|
|
15
|
+
* const pi100 = pi(100)()()
|
|
16
|
+
*
|
|
17
|
+
* expect(pi100).toBeGreaterThan(3.15)
|
|
18
|
+
* expect(pi100).toBeLessThan(3.16)
|
|
19
|
+
*/
|
|
20
|
+
export const recurse = (f, cache = false) => {
|
|
21
|
+
let depth = 0;
|
|
22
|
+
let _cache = null;
|
|
23
|
+
const run = !cache
|
|
24
|
+
? f
|
|
25
|
+
: (_self, _depth) => {
|
|
26
|
+
if (!_cache) {
|
|
27
|
+
_cache = f(_self, _depth);
|
|
28
|
+
}
|
|
29
|
+
return _cache;
|
|
30
|
+
};
|
|
31
|
+
const self = ((...args) => run(self, depth++)(...args));
|
|
32
|
+
return self;
|
|
33
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Predicate } from 'fp-ts/Predicate';
|
|
2
|
+
export declare type Struct = object;
|
|
3
|
+
export declare type PartialDeep<A> = A extends {
|
|
4
|
+
readonly [x: string]: unknown;
|
|
5
|
+
} ? Partial<{
|
|
6
|
+
readonly [K in keyof A]: PartialDeep<A[K]>;
|
|
7
|
+
}> : A;
|
|
8
|
+
declare type IntersectionDeep<A, B> = A extends {
|
|
9
|
+
readonly [x: string]: unknown;
|
|
10
|
+
} ? A & {
|
|
11
|
+
readonly [K in keyof B]: IntersectionDeep<K extends keyof A ? A[K] : unknown, B[K]>;
|
|
12
|
+
} : B;
|
|
13
|
+
export declare const toReadonlyArray: <A extends object>(a: A) => readonly (readonly [keyof A, A[keyof A]])[];
|
|
14
|
+
export declare const filterDeep: <A extends object>(f: Predicate<unknown>) => (a: A) => PartialDeep<A>;
|
|
15
|
+
export declare const patch: <A extends object, B extends PartialDeep<A> & object>(b: B) => (a: A) => IntersectionDeep<A, B>;
|
|
16
|
+
export {};
|
|
@@ -5,9 +5,6 @@ import * as S from 'fp-ts/struct';
|
|
|
5
5
|
import { curry } from './function';
|
|
6
6
|
import * as $t from './Type';
|
|
7
7
|
export const toReadonlyArray = (a) => RR.toReadonlyArray(a);
|
|
8
|
-
export const lookup = (k) => (s) => s[k];
|
|
9
|
-
export const modifyAt = (k, f) => (s) => (Object.assign(Object.assign({}, s), { [k]: f(s[k]) }));
|
|
10
|
-
export const updateAt = (k, a) => modifyAt(k, () => a);
|
|
11
8
|
export const filterDeep = (f) => (a) => pipe(a, toReadonlyArray, RA.filter(([_, value]) => f(value)), RA.map(([key, value]) => $t.struct.is(value)
|
|
12
9
|
? [
|
|
13
10
|
key,
|
package/package.json
CHANGED
|
@@ -1,12 +1,23 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "fortepiano",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "Playing actual music over fp-ts notes",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
7
7
|
"functional-programming",
|
|
8
8
|
"fp-ts",
|
|
9
|
-
"
|
|
9
|
+
"testing"
|
|
10
|
+
],
|
|
11
|
+
"exports": {
|
|
12
|
+
".": {
|
|
13
|
+
"types": "./dist/esm/index.d.ts",
|
|
14
|
+
"require": "./dist/cjs/index.js",
|
|
15
|
+
"import": "./dist/cjs/index.js"
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
"files": [
|
|
19
|
+
"./dist/cjs/**",
|
|
20
|
+
"./dist/esm/**"
|
|
10
21
|
],
|
|
11
22
|
"homepage": "https://github.com/facile-it/fortepiano#readme",
|
|
12
23
|
"bugs": {
|
|
@@ -19,9 +30,9 @@
|
|
|
19
30
|
"license": "MIT",
|
|
20
31
|
"author": "Alberto Villa <villa.alberto@gmail.com>",
|
|
21
32
|
"sideEffects": false,
|
|
22
|
-
"main": "./
|
|
23
|
-
"module": "./esm/index.js",
|
|
24
|
-
"types": "./index.d.ts",
|
|
33
|
+
"main": "./dist/cjs/index.js",
|
|
34
|
+
"module": "./dist/esm/index.js",
|
|
35
|
+
"types": "./dist/esm/index.d.ts",
|
|
25
36
|
"scripts": {
|
|
26
37
|
"prebuild": "yarn clean",
|
|
27
38
|
"build": "yarn prebuild && yarn build:esm && yarn build:cjs",
|
|
@@ -32,73 +43,29 @@
|
|
|
32
43
|
"eslint:fix": "eslint --fix ./",
|
|
33
44
|
"prettier": "prettier --check ./",
|
|
34
45
|
"prettier:fix": "prettier --write ./",
|
|
35
|
-
"prerelease": "yarn build
|
|
36
|
-
"release": "yarn prerelease && npm publish
|
|
46
|
+
"prerelease": "yarn build",
|
|
47
|
+
"release": "yarn prerelease && npm publish",
|
|
37
48
|
"test": "jest",
|
|
49
|
+
"test:watch": "jest --watchAll",
|
|
38
50
|
"test:coverage": "jest --coverage"
|
|
39
51
|
},
|
|
40
52
|
"devDependencies": {
|
|
41
53
|
"@rushstack/eslint-patch": "^1.1.3",
|
|
42
|
-
"@slynova/flydrive": "^1.0.0",
|
|
43
54
|
"@types/jest": "^26.0.24",
|
|
44
|
-
"@types/
|
|
45
|
-
"@types/node-fetch": "^2.5.12",
|
|
46
|
-
"@types/redis": "^2.0.0",
|
|
47
|
-
"@types/redis-mock": "^0.17.0",
|
|
48
|
-
"axios": "^0.28.0",
|
|
55
|
+
"@types/node": "^22.8.7",
|
|
49
56
|
"eslint": "^8.16.0",
|
|
50
57
|
"eslint-config-facile": "^0.5.0",
|
|
51
58
|
"fp-ts": "^2.0.0",
|
|
52
|
-
"got": "^11.0.0",
|
|
53
59
|
"io-ts": "^2.0.0",
|
|
54
|
-
"io-ts-types": "^0.5.0",
|
|
55
60
|
"jest": "^26.6.3",
|
|
56
|
-
"memcached": "^2.0.0",
|
|
57
|
-
"memcached-mock": "^0.1.0",
|
|
58
|
-
"monocle-ts": "^2.3.10",
|
|
59
|
-
"newtype-ts": "^0.3.4",
|
|
60
|
-
"node-fetch": "^2.6.7",
|
|
61
61
|
"prettier": "^2.6.2",
|
|
62
|
-
"redis": "^3.0.0",
|
|
63
|
-
"redis-mock": "^0.56.3",
|
|
64
62
|
"ts-jest": "^26.5.6",
|
|
65
63
|
"ts-node": "^10.9.2",
|
|
66
64
|
"typescript": "^4.6.4"
|
|
67
65
|
},
|
|
68
66
|
"peerDependencies": {
|
|
69
|
-
"
|
|
70
|
-
"
|
|
71
|
-
"@types/redis": "^2.0.0",
|
|
72
|
-
"axios": "^0.21.2 || ^0.28.0",
|
|
73
|
-
"fp-ts": "^2.0.0",
|
|
74
|
-
"got": "^11.0.0",
|
|
75
|
-
"io-ts": "^2.0.0",
|
|
76
|
-
"io-ts-types": "^0.5.0",
|
|
77
|
-
"memcached": "^2.0.0",
|
|
78
|
-
"redis": "^3.0.0"
|
|
79
|
-
},
|
|
80
|
-
"peerDependenciesMeta": {
|
|
81
|
-
"@slynova/flydrive": {
|
|
82
|
-
"optional": true
|
|
83
|
-
},
|
|
84
|
-
"@types/memcached": {
|
|
85
|
-
"optional": true
|
|
86
|
-
},
|
|
87
|
-
"@types/redis": {
|
|
88
|
-
"optional": true
|
|
89
|
-
},
|
|
90
|
-
"axios": {
|
|
91
|
-
"optional": true
|
|
92
|
-
},
|
|
93
|
-
"got": {
|
|
94
|
-
"optional": true
|
|
95
|
-
},
|
|
96
|
-
"memcached": {
|
|
97
|
-
"optional": true
|
|
98
|
-
},
|
|
99
|
-
"redis": {
|
|
100
|
-
"optional": true
|
|
101
|
-
}
|
|
67
|
+
"fp-ts": "^2.5.0",
|
|
68
|
+
"io-ts": "^2.2.0"
|
|
102
69
|
},
|
|
103
|
-
"packageManager": "yarn@
|
|
70
|
+
"packageManager": "yarn@4.18.1"
|
|
104
71
|
}
|
package/Aggregate/package.json
DELETED
package/Aggregate.d.ts
DELETED