Skip to content

Commit 4493827

Browse files
authored
Merge pull request #8 from hyperse-io/feat/pipe
2 parents b5a5324 + 410948f commit 4493827

File tree

12 files changed

+1490
-1222
lines changed

12 files changed

+1490
-1222
lines changed

.changeset/fuzzy-spies-enjoy.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
"@hyperse/pipeline": patch
3+
---
4+
5+
1、adjust ts rules
6+
2、fix typing error

eslint.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ export default defineConfig([
1212
'@typescript-eslint/no-unnecessary-type-constraint': 'off',
1313
'@typescript-eslint/no-unused-vars': 'off',
1414
'@typescript-eslint/prefer-as-const': 'off',
15+
'@typescript-eslint/no-unsafe-function-type': 'off',
1516
},
1617
},
1718
]);

package.json

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -54,27 +54,27 @@
5454
},
5555
"devDependencies": {
5656
"@changesets/changelog-github": "0.5.0",
57-
"@changesets/cli": "2.27.7",
58-
"@commitlint/cli": "19.3.0",
59-
"@commitlint/config-conventional": "19.2.2",
60-
"@hyperse/eslint-config-hyperse": "^1.0.12",
57+
"@changesets/cli": "2.27.9",
58+
"@commitlint/cli": "19.5.0",
59+
"@commitlint/config-conventional": "19.5.0",
60+
"@hyperse/eslint-config-hyperse": "^1.2.6",
6161
"@hyperse/exec-program": "^1.0.10",
62-
"@types/node": "^22.1.0",
63-
"@types/react": "^18.3.3",
64-
"@types/react-dom": "^18.3.0",
65-
"commitizen": "4.3.0",
62+
"@types/node": "^22.7.9",
63+
"@types/react": "^18.3.12",
64+
"@types/react-dom": "^18.3.1",
65+
"commitizen": "4.3.1",
6666
"cz-conventional-changelog": "3.3.0",
67-
"eslint": "^9.8.0",
68-
"husky": "9.1.4",
69-
"lint-staged": "15.2.8",
70-
"next": "14.2.5",
67+
"eslint": "^9.13.0",
68+
"husky": "9.1.6",
69+
"lint-staged": "15.2.10",
70+
"next": "15.0.1",
7171
"npm-run-all": "^4.1.5",
7272
"react": "^18.3.1",
7373
"react-dom": "^18.3.1",
74-
"tsup": "^8.2.4",
75-
"typescript": "^5.5.4",
76-
"vite": "^5.3.5",
77-
"vitest": "^2.0.5"
74+
"tsup": "^8.3.4",
75+
"typescript": "^5.6.3",
76+
"vite": "^5.4.10",
77+
"vitest": "^2.1.3"
7878
},
7979
"engines": {
8080
"node": ">=18"

src/helpers/helper-curry.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { PipeWithFunction } from '../types/types-reactive.js';
1+
import type { PipeWithFunction } from '../types/types-reactive.js';
22

33
const isPlaceholder = (a: any): boolean => {
44
return (

src/helpers/helper-reduce.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { PipeWithFunction } from '../types/types-reactive.js';
1+
import type { PipeWithFunction } from '../types/types-reactive.js';
22
import { curryTwo } from './helper-curry.js';
33
import { isArrayLike } from './helper-is-array-like.js';
44
import { xwrap } from './helper-x-wrap.js';

src/middleware/Pipeline.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Middleware } from '../types/types-middleware.js';
1+
import type { Middleware } from '../types/types-middleware.js';
22
import { invokeMiddlewares } from './invoke.js';
33

44
/**

src/middleware/invoke.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Middleware } from '../types/types-middleware.js';
1+
import type { Middleware } from '../types/types-middleware.js';
22

33
/**
44
* Helper function for invoking a chain of middlewares on a context.

src/reactive/pipe.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,18 @@
11
import { isPromise } from '../helpers/helper-is-promise.js';
22
import { pipeWith } from '../helpers/helper-pipe-with.js';
33
import { fold } from '../types/types-fp-ts.js';
4-
import {
4+
import type {
55
Exists,
66
ExitPipeReturnValue,
7+
PipeCallback,
8+
} from '../types/types-reactive.js';
9+
import {
710
isFpTsEither,
811
isMonetCata,
912
isPurifyEither,
1013
isPurifyEitherAsync,
1114
isPurifyMaybe,
1215
isPurifyMaybeAsync,
13-
PipeCallback,
1416
} from '../types/types-reactive.js';
1517
import type {
1618
ExtractExitPipe1,

src/types/types-purify-either.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import { Just, Maybe, Nothing } from './types-purify-maybe.js';
1+
import type { Maybe } from './types-purify-maybe.js';
2+
import { Just, Nothing } from './types-purify-maybe.js';
23

34
export type EitherPatterns<L, R, T> =
45
| { Left: (l: L) => T; Right: (r: R) => T }

src/types/types-purify-maybe.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
import { Either, Left, Right } from './types-purify-either.js';
1+
import type { Either } from './types-purify-either.js';
2+
import { Left, Right } from './types-purify-either.js';
23

34
export type MaybePatterns<T, U> =
45
| { Just: (value: T) => U; Nothing: () => U }

0 commit comments

Comments
 (0)