pepka 1.6.11 → 1.6.12

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/dist/bundle.d.ts CHANGED
@@ -244,7 +244,10 @@ export declare const test: {
244
244
  };
245
245
  type T_tap = {
246
246
  <T>(fn: (x: T) => any, x: T): T;
247
- (fn: AnyFunc): <T>(x: T) => T;
247
+ (fn: AnyFunc): {
248
+ <T>(x: T): T;
249
+ (): undefined;
250
+ };
248
251
  };
249
252
  export declare const tap: T_tap;
250
253
  export declare const append: {
@@ -324,7 +327,10 @@ export declare const genBy: {
324
327
  };
325
328
  export declare const once: <Func extends AnyFunc>(fn: Func) => (...args: Parameters<Func>) => any;
326
329
  export declare const reverse: <T extends any>(xs: T[]) => T[];
327
- export declare const explore: (caption: string, level?: string) => <T>(x: T) => T;
330
+ export declare const explore: (caption: string, level?: string) => {
331
+ <T>(x: T): T;
332
+ (): undefined;
333
+ };
328
334
  export declare const cond: {
329
335
  (a: symbol, b: any): (a: [
330
336
  Cond,
package/package.json CHANGED
@@ -41,7 +41,7 @@
41
41
  "prod": "npm run gentypes && npm run prod:es && npm run prod:cjs",
42
42
  "all": "npm run dev && npm run prod"
43
43
  },
44
- "version": "1.6.11",
44
+ "version": "1.6.12",
45
45
  "devDependencies": {
46
46
  "@rollup/plugin-commonjs": "^29.0.0",
47
47
  "@rollup/plugin-node-resolve": "^16.0.3",
package/src/safe.ts CHANGED
@@ -130,9 +130,12 @@ export const toPairs = (o: AnyObject | any[]) => Object.entries(o)
130
130
  export const test = curry2((re: RegExp, s: string) => re.test(s))
131
131
  type T_tap = {
132
132
  <T>(fn: (x: T) => any, x: T): T
133
- (fn: AnyFunc): <T>(x: T) => T
133
+ (fn: AnyFunc): {
134
+ <T>(x: T): T
135
+ (): undefined
136
+ }
134
137
  }
135
- export const tap = curry2(<T>(fn: AnyFunc, x: T): T => { fn(x); return x }) as T_tap
138
+ export const tap = curry2(<T>(fn: AnyFunc, x: T): T => { fn(x); return x }) as any as T_tap
136
139
  export const append = curry2((x: any, xs: any[]) => [...xs, x])
137
140
  export const prepend = curry2((x: any, xs: any[]) => [...xs, x])
138
141
  export const flat = (xs: any[]) => xs.flat(inf)