Add settings page for managing forecasting API key and URL via UI
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
cae411eae7
commit
1c411e402e
19809 changed files with 1962608 additions and 97 deletions
35
frontend/node_modules/es-toolkit/dist/fp/array/flattenDeep.mjs
generated
vendored
Normal file
35
frontend/node_modules/es-toolkit/dist/fp/array/flattenDeep.mjs
generated
vendored
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
import { flattenDeep as flattenDeep$1 } from "../../array/flattenDeep.mjs";
|
||||
import { combineEagerAndLazyFunctions, createLazyFunction } from "../_internal/lazy.mjs";
|
||||
//#region src/fp/array/flattenDeep.ts
|
||||
/**
|
||||
* Creates a function that recursively flattens an array.
|
||||
*
|
||||
* The returned function is lazy-capable inside {@link pipe}. A trailing
|
||||
* short-circuiting operator can stop before later nested values are visited.
|
||||
*
|
||||
* @template T - The type of elements in the array.
|
||||
* @returns A function that maps the piped array to a deeply flattened array.
|
||||
*
|
||||
* @example
|
||||
* import { flattenDeep, pipe } from 'es-toolkit/fp';
|
||||
*
|
||||
* pipe([1, [2, [3]]], flattenDeep());
|
||||
* // => [1, 2, 3]
|
||||
*/
|
||||
function flattenDeep() {
|
||||
function flattenDeepEager(array) {
|
||||
return flattenDeep$1(array);
|
||||
}
|
||||
return combineEagerAndLazyFunctions(flattenDeepEager, createLazyFunction((value, _index, emit) => {
|
||||
emitDeep(value, emit);
|
||||
}));
|
||||
}
|
||||
function emitDeep(value, emit) {
|
||||
if (Array.isArray(value)) {
|
||||
for (let index = 0; index < value.length; index++) emitDeep(value[index], emit);
|
||||
return;
|
||||
}
|
||||
emit(value);
|
||||
}
|
||||
//#endregion
|
||||
export { flattenDeep };
|
||||
Loading…
Add table
Add a link
Reference in a new issue