18 Commits

Author SHA1 Message Date
Samuel Berthe fa095e4b4f fix(doc): fix go playground demo URL (#832)
* fix(doc): fix go playground demo URL

* fix(doc): add more go playground demo URL
2026-03-06 00:09:59 +01:00
d-enk 7a0a18b3a4 perf: optimize PartitionBy by eliminating redundant append (#765)
New groups are now initialized with the first element directly,
avoiding an extra append operation in the hot loop.

Use a one style for lo/it/parallel
2026-01-12 20:58:04 +01:00
Nathan Baulch e7386d9246 lint: fix inconsistent callback function parameter names (#730)
* Fix linting

* Use is.ElementsMatch

This will ignore the ordering of the final intersection. Especially
important when checking old versions of go that do not guarantee an order
when iterating through maps.

* lint: fix inconsistent callback function parameter names

* lint: rename "iteratee" to "transform" for *Map helpers

* lint: rename "project" parameters to "transform"

* lint: rename "cb" parameters to "callback"

* lint: rename "iteratee" to "callback" for ForEach helpers

---------

Co-authored-by: Franky W. <frankywahl@users.noreply.github.com>
Co-authored-by: Samuel Berthe <dev@samuel-berthe.fr>
2025-11-06 18:05:11 +01:00
Nathan Baulch f5aac81cc0 lint: enable gofumpt extra rules (#690)
Co-authored-by: Samuel Berthe <dev@samuel-berthe.fr>
2025-09-26 13:32:59 +02:00
Nathan Baulch 3e11f11781 docs: grammar improvements (#673)
* lint: pin golangci-lint version

* docs: grammar fixes

* docs: remove "truthy" terminology

* docs: remove "array" terminology

* docs: grammar fixes

* Update .github/workflows/lint.yml

---------

Co-authored-by: Samuel Berthe <dev@samuel-berthe.fr>
2025-09-24 20:59:41 +02:00
Samuel Berthe 3bc887c57c doc: adding go playground examples 2025-09-23 14:54:30 +02:00
Yishuai Li 5512d3afc2 fix(parallel): order of GroupBy and PartitionBy (#572) 2025-01-24 14:47:52 +01:00
Samuel Berthe 93686db8b5 feat: preserve type alias of slices and maps (see #365) 2024-06-30 00:08:47 +02:00
Samuel Berthe 7887963db8 feat: name each callback/iteratee/predicate arguments in order to improve autocompletion
closes #242
2022-10-13 22:25:33 +02:00
Sergey Dobrodey f09091140d parallel/slice.go GroupBy
reduce number of reads
2022-03-25 17:30:35 +02:00
francisco souza 25fe06d08e parallel: remove mutex from Map and Times
The slice is pre-allocated, a mutex is not needed.
2022-03-05 18:24:22 -05:00
Samuel Berthe 094b6f974f run test with race condition detector 2022-03-06 00:23:52 +01:00
Samuel Berthe 8d3debc990 Merge branch 'master' of github.com:samber/lo 2022-03-06 00:22:34 +01:00
Samuel Berthe 28bec027ee oops 2022-03-06 00:21:23 +01:00
francisco souza a43b3a8e79 parallel: fix PartitionBy
Should fix the tests.
2022-03-05 17:49:15 -05:00
Samuel Berthe 2d3ea84ba6 feat: adding attempt + repeat + times 2022-03-05 21:24:37 +01:00
Samuel Berthe 0c3545daf3 feat: adding lo.PartitionBy + lop.PartitionBy + lo.GroupBy 2022-03-05 18:44:39 +01:00
Samuel Berthe 2566a935f2 adding lop.Map and lop.ForEach 2022-03-03 16:15:17 +01:00