Skip to content

Commit a592e0f

Browse files
author
Arvid Nicolaas
committed
refactor: update dependency versions
1 parent 89842dd commit a592e0f

File tree

259 files changed

+4779
-4320
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

259 files changed

+4779
-4320
lines changed

.husky/pre-commit

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1 @@
1-
#!/bin/sh
2-
. "$(dirname "$0")/_/husky.sh"
3-
41
npx lint-staged

config/.eslintrc.json

Lines changed: 0 additions & 31 deletions
This file was deleted.

config/eslint.config.mjs

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
import pluginJs from '@eslint/js';
2+
import tseslint from 'typescript-eslint';
3+
import eslintPLuginPrettier from 'eslint-plugin-prettier/recommended';
4+
5+
export default tseslint.config(
6+
eslintPLuginPrettier,
7+
pluginJs.configs.recommended,
8+
tseslint.configs.recommended,
9+
{
10+
rules: {
11+
// 'no-constant-condition': 'warn',
12+
// 'no-inner-declarations': 'warn',
13+
// 'unused-imports/no-unused-imports': 'error',
14+
'no-unexpected-multiline': 'warn',
15+
'@typescript-eslint/consistent-type-imports': [
16+
'error',
17+
{ fixStyle: 'inline-type-imports' },
18+
],
19+
'@typescript-eslint/explicit-function-return-type': 'error',
20+
'@typescript-eslint/no-empty-interface': 'off',
21+
'@typescript-eslint/no-explicit-any': 'off',
22+
'@typescript-eslint/no-namespace': 'off',
23+
'@typescript-eslint/no-empty-object-type': 'off',
24+
'@typescript-eslint/no-unused-vars': 'warn',
25+
'@typescript-eslint/no-wrapper-object-types': 'warn',
26+
},
27+
},
28+
{
29+
ignores: [
30+
'**/test/',
31+
'**/test-d/',
32+
'**/docs/',
33+
'*.js',
34+
'*.mjs',
35+
'**/doc-gen/',
36+
'**/deno_dist/',
37+
],
38+
}
39+
);

deno_dist/actor/immer/slice-immer.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export namespace SliceImmer {
88
export interface Config extends SliceConfig {
99
_ACTION_HANDLER_ARGS: [
1010
this['_STATE'],
11-
...this['_ACTION_HANDLER_UNKNOWN'][]
11+
...this['_ACTION_HANDLER_UNKNOWN'][],
1212
];
1313

1414
_ACTION_HANDLER: (...args: this['_ACTION_HANDLER_ARGS']) => void;
@@ -17,7 +17,7 @@ export namespace SliceImmer {
1717

1818
_INCLUDE_HANDLER_ARGS: [
1919
state: this['_STATE'],
20-
action: this['_INCLUDE_ACTION_TYPE']
20+
action: this['_INCLUDE_ACTION_TYPE'],
2121
];
2222

2323
_INCLUDE_HANDLER: (...args: this['_INCLUDE_HANDLER_ARGS']) => void;

deno_dist/actor/main/actor.ts

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import type { ActionBase } from './internal.ts';
77
export interface Actor<
88
S,
99
D extends (...args: any[]) => any = (action: ActionBase) => void,
10-
ACS extends Actor.ActionsDefinition = Record<string, never>
10+
ACS extends Actor.ActionsDefinition = Record<string, never>,
1111
> extends Actor.Base<S>,
1212
Actor.Dispatch<D>,
1313
Actor.ActionsDispatch<ACS, D> {}
@@ -23,7 +23,7 @@ export namespace Actor {
2323
export type DispatchFunction = (...args: any[]) => any;
2424

2525
export interface Dispatch<
26-
D extends Actor.DispatchFunction = (action: ActionBase) => void
26+
D extends Actor.DispatchFunction = (action: ActionBase) => void,
2727
> {
2828
dispatch: D;
2929
}
@@ -33,14 +33,14 @@ export namespace Actor {
3333
};
3434

3535
export interface Actions<
36-
AC extends Actor.ActionsDefinition = Record<string, never>
36+
AC extends Actor.ActionsDefinition = Record<string, never>,
3737
> {
3838
actions: AC;
3939
}
4040

4141
export type ActionsToDispatch<
4242
AC extends Actor.ActionsDefinition,
43-
D extends Actor.DispatchFunction
43+
D extends Actor.DispatchFunction,
4444
> = {
4545
[K in keyof AC]: AC[K] extends (...args: any[]) => any
4646
? (...args: Parameters<AC[K]>) => ReturnType<D>
@@ -49,16 +49,13 @@ export namespace Actor {
4949

5050
export interface ActionsDispatch<
5151
AC extends Actor.ActionsDefinition,
52-
D extends Actor.DispatchFunction
52+
D extends Actor.DispatchFunction,
5353
> {
5454
actions: Actor.ActionsToDispatch<AC, D>;
5555
}
5656

57-
export type StateType<A extends Actor.Base<any>> = A extends Actor.Base<
58-
infer S
59-
>
60-
? S
61-
: unknown;
57+
export type StateType<A extends Actor.Base<any>> =
58+
A extends Actor.Base<infer S> ? S : unknown;
6259

6360
export type Listener = () => void;
6461

@@ -71,7 +68,7 @@ export namespace Actor {
7168
EnhancedActor extends Actor.Dispatch<any> &
7269
Actor.Actions<any> & { actionCreators: AC } = Actor<S, D, AC> & {
7370
actionCreators: AC;
74-
}
71+
},
7572
>(config: {
7673
reducer: Actor.ActionReducer<S>;
7774
actions?: AC | undefined;
@@ -152,7 +149,7 @@ export namespace Actor {
152149

153150
function createDispatchActions<
154151
A extends Actor.ActionsDefinition,
155-
D extends Actor.DispatchFunction
152+
D extends Actor.DispatchFunction,
156153
>(
157154
source: A | undefined,
158155
actor: { dispatch: D }

deno_dist/actor/main/slice-config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ export namespace SliceConfig {
9494
* @typeparam C - the slice configuration type
9595
*/
9696
export type ActionIncluder<S, C extends SliceConfig> = <
97-
AC extends ActionBase
97+
AC extends ActionBase,
9898
>(
9999
action: ActionBase.Creator<AC, any[]>,
100100
handler: (C & { _STATE: S; _INCLUDE_ACTION_TYPE: AC })['_INCLUDE_HANDLER']

deno_dist/actor/main/slice.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ export namespace Slice {
2424
export interface Config extends SliceConfig {
2525
_ACTION_HANDLER_ARGS: [
2626
this['_STATE'],
27-
...this['_ACTION_HANDLER_UNKNOWN'][]
27+
...this['_ACTION_HANDLER_UNKNOWN'][],
2828
];
2929

3030
_ACTION_HANDLER_RESULT: this['_STATE'];
@@ -33,7 +33,7 @@ export namespace Slice {
3333

3434
_INCLUDE_HANDLER_ARGS: [
3535
state: this['_STATE'],
36-
action: this['_INCLUDE_ACTION_TYPE']
36+
action: this['_INCLUDE_ACTION_TYPE'],
3737
];
3838

3939
_ACTION_TYPE: Action<Tail<Parameters<this['_ACTION_HANDLER']>>>;
@@ -57,7 +57,7 @@ export namespace Slice {
5757
});
5858

5959
export interface CombinedSlice<
60-
SDef extends Record<string, Slice<any, Record<string, any>>>
60+
SDef extends Record<string, Slice<any, Record<string, any>>>,
6161
> {
6262
reducer: Actor.ActionReducer<{
6363
[K in keyof SDef]: Slice.StateType<SDef[K]>;

deno_dist/bimultimap/custom/implementation/builder.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export class BiMultiMapBuilder<
1414
K,
1515
V,
1616
Tp extends ContextTypesImpl,
17-
TpG extends WithKeyValue<Tp, K, V> = WithKeyValue<Tp, K, V>
17+
TpG extends WithKeyValue<Tp, K, V> = WithKeyValue<Tp, K, V>,
1818
> implements BiMultiMapBase.Builder<K, V, Tp>
1919
{
2020
_lock = 0;

deno_dist/bimultimap/custom/implementation/context.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ export class BiMultiMapContext<
1818
UK,
1919
UV,
2020
N extends string,
21-
Tp extends ContextTypesImpl = ContextTypesImpl
21+
Tp extends ContextTypesImpl = ContextTypesImpl,
2222
> implements BiMultiMapBase.Context<UK, UV, Tp>
2323
{
2424
constructor(

deno_dist/bimultimap/custom/implementation/immutable.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ export class BiMultiMapNonEmpty<
133133
K,
134134
V,
135135
Tp extends ContextTypesImpl,
136-
TpG extends WithKeyValue<Tp, K, V> = WithKeyValue<Tp, K, V>
136+
TpG extends WithKeyValue<Tp, K, V> = WithKeyValue<Tp, K, V>,
137137
>
138138
extends NonEmptyBase<[K, V]>
139139
implements BiMultiMapBase.NonEmpty<K, V, Tp>

deno_dist/bimultimap/custom/interface/base.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import type {
2121
export interface BiMultiMapBase<
2222
K,
2323
V,
24-
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types
24+
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types,
2525
> extends FastIterable<[K, V]> {
2626
/**
2727
* Returns the `context` associated to this collection instance.
@@ -409,7 +409,7 @@ export namespace BiMultiMapBase {
409409
export interface NonEmpty<
410410
K,
411411
V,
412-
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types
412+
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types,
413413
> extends BiMultiMapBase<K, V, Tp>,
414414
Streamable.NonEmpty<[K, V]> {
415415
/**
@@ -503,7 +503,7 @@ export namespace BiMultiMapBase {
503503
export interface Factory<
504504
UK = unknown,
505505
UV = unknown,
506-
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types
506+
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types,
507507
> {
508508
/**
509509
* Returns the (singleton) empty instance of this type and context with given key and value types.
@@ -567,7 +567,7 @@ export namespace BiMultiMapBase {
567567
export interface Context<
568568
UK,
569569
UV,
570-
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types
570+
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types,
571571
> extends BiMultiMapBase.Factory<UK, UV, Tp> {
572572
readonly _fixTypes: readonly [UK, UV];
573573

@@ -596,7 +596,7 @@ export namespace BiMultiMapBase {
596596
export interface Builder<
597597
K,
598598
V,
599-
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types
599+
Tp extends BiMultiMapBase.Types = BiMultiMapBase.Types,
600600
> {
601601
/**
602602
* Returns the amount of entries in the builder.

deno_dist/channel/custom/channel/channel.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,8 @@ export namespace Channel {
135135
C extends Channel.Read<infer T>
136136
? T
137137
: C extends Channel.Write<infer T>
138-
? T
139-
: never;
138+
? T
139+
: never;
140140

141141
/**
142142
* The Channel Error type.
@@ -233,7 +233,7 @@ export namespace Channel {
233233
TS extends any[],
234234
HS extends {
235235
[K in keyof TS]: [Channel.Read<TS[K]>, (value: TS[K]) => any];
236-
}
236+
},
237237
>(
238238
options?: {
239239
signal?: AbortSignal | undefined;
@@ -249,7 +249,7 @@ export namespace Channel {
249249
HS extends {
250250
[K in keyof TS]: [Channel.Read<TS[K]>, (value: TS[K]) => any];
251251
},
252-
RT
252+
RT,
253253
>(
254254
options: {
255255
signal?: AbortSignal | undefined;
@@ -339,7 +339,7 @@ export const Channel: Channel.Constructors = Object.freeze(
339339
HS extends {
340340
[K in keyof TS]: [Channel.Read<TS[K]>, (value: TS[K]) => any];
341341
},
342-
RT
342+
RT,
343343
>(
344344
options: {
345345
signal?: AbortSignal | undefined;

deno_dist/channel/custom/cross-channel/cross-channel.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export namespace CrossChannel {
2121
*/
2222
export type Pair<TSend, TReceive> = readonly [
2323
crossSendCh: CrossChannel<TSend, TReceive>,
24-
crossReceiveCh: CrossChannel<TReceive, TSend>
24+
crossReceiveCh: CrossChannel<TReceive, TSend>,
2525
];
2626

2727
/**

deno_dist/channel/custom/remote-channel/remote-channel-impl.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,9 @@ export class RemoteChannelRead<T>
378378
try {
379379
const { sourceInstanceId } = await this.receiveMessage(
380380
'OPEN_CHANNEL_REQUEST',
381-
{ timeoutMs: handshakeAttemptTimeoutMs }
381+
{
382+
timeoutMs: handshakeAttemptTimeoutMs,
383+
}
382384
);
383385

384386
let instanceId = getRandomSequenceNumber();
@@ -446,7 +448,7 @@ export class RemoteChannelRead<T>
446448
});
447449

448450
this.postMessage('SEND_VALUE_RESPONSE', { accepted: true });
449-
} catch (err) {
451+
} catch {
450452
this.postMessage('SEND_VALUE_RESPONSE', { accepted: false });
451453
}
452454
}

deno_dist/channel/custom/rpc-proxy/rpc-proxy.ts

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,16 @@ export namespace RpcProxy {
3434
* type be asynchronous.
3535
* @typeparam T - the source type to unpromise
3636
*/
37-
export type Unpromise<T> = T extends Promise<infer R>
38-
? Unpromise<R>
39-
: T extends (...args: infer A) => infer R
40-
? (...args: A) => Unpromise<R>
41-
: T extends readonly any[]
42-
? { readonly [K in keyof T]: Unpromise<T[K]> }
43-
: T extends Record<any, any>
44-
? { readonly [K in keyof T]: Unpromise<T[K]> }
45-
: T;
37+
export type Unpromise<T> =
38+
T extends Promise<infer R>
39+
? Unpromise<R>
40+
: T extends (...args: infer A) => infer R
41+
? (...args: A) => Unpromise<R>
42+
: T extends readonly any[]
43+
? { readonly [K in keyof T]: Unpromise<T[K]> }
44+
: T extends Record<any, any>
45+
? { readonly [K in keyof T]: Unpromise<T[K]> }
46+
: T;
4647

4748
/**
4849
* The RpcProxy error type

0 commit comments

Comments
 (0)