Closed lqhuang closed 1 week ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
es-toolkit | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Aug 26, 2024 2:39pm |
Hello :) Thanks for the suggestion! I see the need for this function, but I'm still not sure how frequently it will be used by our users. We might consider defining it in each repository where it's needed, but not in es-toolkit. What do you think?
@raon0211 Thanks for reply! Never mind, it's fine to close. I totally understand this function doesn't include in loadash
either. I just thought es-toolkit
could have more usage cases than lodash
.
Feel free to close 😄, or just keep it open until other people show interesting on this feature or provide more feedbacks.
Thanks for your understanding! :)
Hi there,
Thanks for such amazing lib. I'm trying to transform consecutive discriminated union elements have the same key in an array into a new array with grouped unions, but I only found
groupBy
function.Hence, here I want to propose a new function on array toolkits to transform things I described above.
You could see the details in src changes. And there are some notable comments
index.ts
groupConsecutiveBy
is enough concise and short. The function name could be changed if we have a better one (likechunkConsecutiveBy
?).It will be greatly appreciated if anyone provide suggestions to improve it!
Regards