Go Funk Versions Save

A modern Go utility library which provides helpers (map, find, contains, filter, ...)

v0.9.3

1 year ago

v0.9.2

2 years ago

v0.9.1

2 years ago

Fix unix format for short_if.go.

v0.9.0

2 years ago
  • (BC) Typesafe Min*, Max* previously returned a nil pointer when the argument does not contain any items, it has been changed to have a typesafe signature and it panics
  • Add StringerJoin which joins an array of elements which implement the String() string function (thks @arnovanliere)
  • Update Get to allows zero values with the option WithAllowZero (thks @roneli)
  • Add typesafe bool functions FilterBool, ContainsBool, InBools, IndexOfBool, LastIndexOfBool, UniqBool, DropBool, ShuffleBool, ReverseBools (thks @arnovanliere)
  • Update Zip to panic when the passing argument is not a slice / array

v0.8.0

3 years ago
  • Reduce now returns an interface
  • Add FlapMap which manipulates an iteratee (map, slice) and transforms it to to a flattened collection of another type
  • Add support for map when using Get
  • Add Set which sets value at a path of a struct
  • Add DifferenceInt64, DifferenceInt32, DifferenceInt, DifferenceUInt, DifferenceUInt32, DifferenceUInt64
  • Add Flatten which flattens a two-dimensional array.
  • Add Prune which returns a copy of "in" that only contains fields in "paths"

Thank you @youyuanwu @vellotis @guyarb @nohponex @CengSin @samber @HarryWang29

v0.7.0

3 years ago
  • Add Join which combines two collections using the given join method (thks @xunleii)
  • Add Without which creates an array excluding all given values (thks @xunleii)
  • Add Subset which returns true if a collection is a subset of another (thks @reetuparna)
  • Add Join operations, primitives (InnerJoin, OuterJoin, LeftJoin, RightJoin) and typesafe implementations (thks @xunleii)
  • Fixed input mutation in Uniq, it returns a copy of the input without the duplicate
  • Fixed some typos (thks @anukul)
  • Fixed SubtractString when an empty array is passed (thks @alongat)

v0.6.0

4 years ago
  • Add Intersect returns the intersection between two collections (thks @samber)
  • Add Difference returns the difference between two collections (thks @samber)
  • Add GetOrElse retrieves the value of the point or default (thks @samber)
  • Add Subtract the subtraction between two collections. It preserves order (thks @airani)
  • Fix bug in lastIndexOf (thks @kkty)

v0.5.0

4 years ago
  • Add Max* methods (thks @abshek)
  • Add Min* methods (thks @CatInCosmicSpace)
  • Fix typos (thks @flowonyx)
  • Handle zero value in Chunk
  • Add FindKey to iterate over elements of collection, returning the first
  • Add Some to return true if at least one element is present in an iteratee

v0.4.0

5 years ago
  • Add Intersect , IntersectString (thks @novln)
  • Add chain builders to chain method calls (thks @xunleii)

v0.3.0

5 years ago
  • More Go versions have been added to the CI (thks @ferhatelmas, @HaraldNordgren)
  • Add Compact (thks @poporul)
  • Add Reduce which reduces an iterable based on a function (thks @poporul)
  • Add Zip which zip two iterables (thks @HaraldNordgren)
  • Add Fill which fills an iterable with a value (thks @HaraldNordgren)
  • Add Every which returns true if every element is present in a iteratee (thks @HaraldNordgren)
  • Add Any which returns true if any element of the iterable is not empty. If the iterable is empty, return False.
  • Add All which returns true if all elements of the iterable are not empty (or if the iterable is empty)
  • Add ConvertSlice which converts a slice to a desired type
  • Add Drop which creates an array/slice with n elements dropped from the beginning (thks @spoonscen)
  • Missing documentation for Compact and Reduce (thks @alexander-yu)
  • Reduce memory usage for Uniq functions (thks @orvice)