@kakasoo/proto-typescript
Advanced tools
Comparing version
@@ -6,3 +6,9 @@ import { NeverType } from './never.type'; | ||
export declare namespace ArrayType { | ||
type Filter = any; | ||
type _FilterNull<AllowNull extends boolean, Target> = [ | ||
...(AllowNull extends false ? (Equal<Target, null> extends true ? [] : [Target]) : [Target]) | ||
]; | ||
type _FilterUndefined<AllowUndefined extends boolean, Target> = [ | ||
...(AllowUndefined extends false ? (Equal<Target, undefined> extends true ? [] : [Target]) : [Target]) | ||
]; | ||
type Filter<T extends ReadonlyOrNot<any[]>, AllowNull extends boolean, AllowUndefined extends boolean> = T extends [infer First, ...infer Rest] ? [..._FilterNull<AllowNull, First>, Filter<Rest, AllowNull, AllowUndefined>] : []; | ||
/** | ||
@@ -9,0 +15,0 @@ * Get length of tuple or string literal type. |
{ | ||
"name": "@kakasoo/proto-typescript", | ||
"version": "1.26.4", | ||
"version": "1.26.5", | ||
"publishConfig": { | ||
@@ -5,0 +5,0 @@ "access": "public" |
Sorry, the diff of this file is not supported yet
194240
0.62%1895
0.32%