big-cartesian
Advanced tools
Comparing version 4.5.0 to 4.6.0
@@ -18,7 +18,7 @@ /** | ||
*/ | ||
export default function bigCartesian<InputArrays extends InputArray[]>(iterables: [...InputArrays]): CartesianProducts<InputArrays>; | ||
export default function bigCartesian<InputArrays extends InputArray[]>(iterables: readonly [...InputArrays]): CartesianProducts<InputArrays>; | ||
type CartesianProducts<InputArrays extends InputArray[]> = Generator<{ | ||
[index in keyof InputArrays]: InputArrays[index] extends (infer InputElement)[] ? InputElement : InputArrays[index] extends Iterable<infer InputElement> ? InputElement : InputArrays[index] extends () => Generator<infer InputElement> ? InputElement : never; | ||
}, void, void>; | ||
type InputArray = unknown[] | Iterable<unknown> | (() => Generator<unknown>); | ||
type InputArray = unknown[] | Iterable<unknown> | (() => Generator); | ||
export {}; |
@@ -77,4 +77,8 @@ | ||
const getResults=function*( | ||
iteratorFuncs) | ||
{ | ||
@@ -113,2 +117,3 @@ const iterators=iteratorFuncs.map(getIterator); | ||
typeof value==="object"&& | ||
value!==null&& | ||
@@ -161,3 +166,3 @@ typeof value.next==="function"); | ||
} | ||
}else if(done){ | ||
}else if(done===true){ | ||
reset=true; | ||
@@ -164,0 +169,0 @@ iterators[index]=iteratorFuncs[index](); |
{ | ||
"name": "big-cartesian", | ||
"version": "4.5.0", | ||
"version": "4.6.0", | ||
"type": "module", | ||
@@ -26,4 +26,4 @@ "exports": { | ||
"sets", | ||
"functional", | ||
"functional-programming", | ||
"functional", | ||
"product", | ||
@@ -56,4 +56,4 @@ "iterable", | ||
"devDependencies": { | ||
"@ehmicky/dev-tasks": "^2.0.30", | ||
"pretty-format": "^29.0.1" | ||
"@ehmicky/dev-tasks": "^2.0.52", | ||
"test-each": "^5.6.0" | ||
}, | ||
@@ -60,0 +60,0 @@ "engines": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
20040