LittleDemon WebShell


Linux premium331.web-hosting.com 4.18.0-553.80.1.lve.el8.x86_64 #1 SMP Wed Oct 22 19:29:36 UTC 2025 x86_64
Path : /home/livedhms/lmgt/node_modules/remeda/dist/
File Upload :
Command :
Current File : /home/livedhms/lmgt/node_modules/remeda/dist/dropLastWhile.cjs.map

{"version":3,"file":"dropLastWhile.cjs","names":["purry"],"sources":["../src/dropLastWhile.ts"],"sourcesContent":["import type { IterableContainer } from \"./internal/types/IterableContainer\";\nimport { purry } from \"./purry\";\n\n/**\n * Removes elements from the end of the array until the predicate returns false.\n *\n * The predicate is applied to each element in the array starting from the end and moving towards the beginning, until the predicate returns false. The returned array includes elements from the beginning of the array, up to and including the element that produced false for the predicate.\n *\n * @param data - The array.\n * @param predicate - The predicate.\n * @signature\n *    R.dropLastWhile(data, predicate)\n * @example\n *    R.dropLastWhile([1, 2, 10, 3, 4], x => x < 10) // => [1, 2, 10]\n * @dataFirst\n * @category Array\n */\nexport function dropLastWhile<T extends IterableContainer>(\n  data: T,\n  predicate: (item: T[number], index: number, data: T) => boolean,\n): T[number][];\n\n/**\n * Removes elements from the end of the array until the predicate returns false.\n *\n * The predicate is applied to each element in the array starting from the end and moving towards the beginning, until the predicate returns false. The returned array includes elements from the beginning of the array, up to and including the element that produced false for the predicate.\n *\n * @param predicate - The predicate.\n * @signature\n *    R.dropLastWhile(predicate)(data)\n * @example\n *    R.pipe([1, 2, 10, 3, 4], R.dropLastWhile(x => x < 10))  // => [1, 2, 10]\n * @dataLast\n * @category Array\n */\nexport function dropLastWhile<T extends IterableContainer>(\n  predicate: (item: T[number], index: number, data: T) => boolean,\n): (data: T) => T[number][];\n\nexport function dropLastWhile(...args: readonly unknown[]): unknown {\n  return purry(dropLastWhileImplementation, args);\n}\n\nfunction dropLastWhileImplementation<T extends IterableContainer>(\n  data: T,\n  predicate: (item: T[number], index: number, data: T) => boolean,\n): T[number][] {\n  for (let i = data.length - 1; i >= 0; i--) {\n    if (!predicate(data[i], i, data)) {\n      return data.slice(0, i + 1);\n    }\n  }\n  return [];\n}\n"],"mappings":"wCAuCA,SAAgB,EAAc,GAAG,EAAmC,CAClE,OAAOA,EAAAA,EAAM,EAA6B,EAAK,CAGjD,SAAS,EACP,EACA,EACa,CACb,IAAK,IAAI,EAAI,EAAK,OAAS,EAAG,GAAK,EAAG,IACpC,GAAI,CAAC,EAAU,EAAK,GAAI,EAAG,EAAK,CAC9B,OAAO,EAAK,MAAM,EAAG,EAAI,EAAE,CAG/B,MAAO,EAAE"}

LittleDemon - FACEBOOK
[ KELUAR ]