Skip to content

Commit

Permalink
Change reference prop of action base types to be less strict #799
Browse files Browse the repository at this point in the history
  • Loading branch information
fabian-hiller committed Aug 30, 2024
1 parent 23b1ebf commit be76dc7
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 9 deletions.
4 changes: 4 additions & 0 deletions library/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

All notable changes to the library will be documented in this file.

## vX.X.X (Month DD, YYYY)

- Change `reference` property of all action base types to be less strict (issue #799)

## v0.40.0 (August 29, 2024)

- Add `nanoid` action to validate Nano IDs (pull request #789)
Expand Down
3 changes: 2 additions & 1 deletion library/src/types/metadata.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ export interface BaseMetadata<TInput> {
readonly reference: (
// eslint-disable-next-line @typescript-eslint/no-explicit-any
...args: any[]
) => BaseMetadata<TInput>;
// eslint-disable-next-line @typescript-eslint/no-explicit-any
) => BaseMetadata<any>;
/**
* Input, output and issue type.
*
Expand Down
10 changes: 6 additions & 4 deletions library/src/types/transformation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ export interface BaseTransformation<
readonly reference: (
// eslint-disable-next-line @typescript-eslint/no-explicit-any
...args: any[]
) => BaseTransformation<TInput, TOutput, TIssue>;
// eslint-disable-next-line @typescript-eslint/no-explicit-any
) => BaseTransformation<any, any, BaseIssue<unknown>>;
/**
* Whether it's async.
*/
Expand Down Expand Up @@ -72,9 +73,10 @@ export interface BaseTransformationAsync<
readonly reference: (
// eslint-disable-next-line @typescript-eslint/no-explicit-any
...args: any[]
) =>
| BaseTransformation<TInput, TOutput, TIssue>
| BaseTransformationAsync<TInput, TOutput, TIssue>;
) => // eslint-disable-next-line @typescript-eslint/no-explicit-any
| BaseTransformation<any, any, BaseIssue<unknown>>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
| BaseTransformationAsync<any, any, BaseIssue<unknown>>;
/**
* Whether it's async.
*/
Expand Down
10 changes: 6 additions & 4 deletions library/src/types/validation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ export interface BaseValidation<
readonly reference: (
// eslint-disable-next-line @typescript-eslint/no-explicit-any
...args: any[]
) => BaseValidation<TInput, TOutput, TIssue>;
// eslint-disable-next-line @typescript-eslint/no-explicit-any
) => BaseValidation<any, any, BaseIssue<unknown>>;
/**
* The expected property.
*/
Expand Down Expand Up @@ -76,9 +77,10 @@ export interface BaseValidationAsync<
readonly reference: (
// eslint-disable-next-line @typescript-eslint/no-explicit-any
...args: any[]
) =>
| BaseValidation<TInput, TOutput, TIssue>
| BaseValidationAsync<TInput, TOutput, TIssue>;
) => // eslint-disable-next-line @typescript-eslint/no-explicit-any
| BaseValidation<any, any, BaseIssue<unknown>>
// eslint-disable-next-line @typescript-eslint/no-explicit-any
| BaseValidationAsync<any, any, BaseIssue<unknown>>;
/**
* Whether it's async.
*/
Expand Down

0 comments on commit be76dc7

Please sign in to comment.