Skip to content

Releases: kevin-lee/just-fp

v1.6.0

15 May 08:56
2d593c9
Compare
Choose a tag to compare

1.6.0 - 2021-05-15

Done

  • Drop Scala 2.10 support (#210)
  • Support Scala 3.0.0 (#212)

v1.5.0

23 Apr 12:42
6a7803d
Compare
Choose a tag to compare

1.5.0 - 2021-04-23

Done

  • Support Scala 3.0.0-RC3 (#202)

v1.4.0

17 Apr 23:23
3320bfb
Compare
Choose a tag to compare

1.4.0 - 2021-04-18

Done

  • Add OptionT (#132)
  • Add the document site using sbt-microsites (#142)
  • Add core sub-project (#143)
  • Replace sbt-microsites with Docusaurus (#165)
  • Build for Dotty (#170)
  • Support Scala 3.0.0-M2 (#180)
  • Support Scala 3.0.0-M3, Scala 3.0.0-RC1 and Scala 3.0.0-RC2 (#186)
  • Use Scalafix (#190)
  • Drop Scala 3.0.0-M* support (#192)

v1.3.5

31 Oct 06:13
9533647
Compare
Choose a tag to compare

1.3.5 - 2019-10-31 🎃👻

Done

  • Use GitHub Actions for Maven Central sync (#127)

    (Internal CI / CD change)

v1.3.4

18 Oct 11:13
f9e02ce
Compare
Choose a tag to compare

1.3.4 - 2019-10-18

Done

  • Only project homepage and scm info have been added for release.

v1.3.3

18 Oct 09:39
d0c7f66
Compare
Choose a tag to compare

1.3.3 - 2019-10-18

Done

  • Nothing. It is released just to sign the artifacts with GPG.

v1.3.2

18 Oct 03:15
fad0ed3
Compare
Choose a tag to compare

1.3.2 - 2019-10-18

Done

  • Set up GitHub Actions (#113)
  • Change group id for publishing to io.kevinlee (#116)

NOTE: No important changes to public. Only the group ID is not io.kevinlee which was kevinlee before.

v1.3.1

15 Oct 01:23
0f1722f
Compare
Choose a tag to compare

1.3.1 - 2019-10-15

Done

  • Add apply method to the companion objects of typeclasses (#102)

    This

    implicitly[Monoid[List[A]]].zero // List[Int] = List()

    can be now

    Monoid[List[Int]].zero // List[Int] = List()

    Also for the following typeclasses

    • Equal

      e.g) when there is the instance of Equal[A] typeclass

      Equal[List[Int]].equal(List(1, 2, 3), List(1, 2, 3)) // true
    • SemiGroup

      SemiGroup[Int].append(1, 2) // Int = 3
    • Monoid

      Monoid[List[Int]].append(List(1, 2, 3), Monoid[List[Int]].zero)
      // List[Int] = List(1, 2, 3)
    • Functor

      Functor[Option].map(1.some)(_ + 99)
      // Option[Int] = Some(100)
    • Applicative

      Applicative[List].ap(List(1, 2, 3))(List[Int => Int](n => n * 2, _ + 99))
      // List[Int] = List(2, 4, 6, 100, 101, 102)
    • Monad

      Monad[Option].flatMap(1.some)(n => (n + 99).some)
      // Option[Int] = Some(100)
  • Add isZero to Monoid (#104)

    e.g.)

    Monoid[List[Int]].isZero(Monoid[List[Int]].zero) // true
    Monoid[List[Int]].isZero(List()) // true
    Monoid[List[Int]].isZero(List(1, 2, 3)) // false
  • Add nonZero to Monoid (#106)

    e.g.)

    Monoid[List[Int]].nonZero(Monoid[List[Int]].zero) // false
    Monoid[List[Int]].nonZero(List()) // false
    Monoid[List[Int]].nonZero(List(1, 2, 3)) // true

v1.3.0

13 Oct 05:13
Compare
Choose a tag to compare

1.3.0 - 2019-10-13

Done

  • Add writer syntax (#89)

    e.g.)

    1.writer("Get value")
    // Writer[String,Int] = WriterT(("Get value",1))
    // WriterT[Id, String, Int]
    
    "something".writer(List("something happened"))
    // Writer[List[String],String] = WriterT((List("something happened"),"something"))
    // WriterT[Id, List[String], String]
  • Add Writer constructor for (W, A) (#87)

    e.g.)

    for {
      a <- Writer.writer(("abc", 1))
      b <- Writer.writer(("def", a))
    } yield b
    // WriterT[Id,String,Int] = WriterT(("abcdef",1))
  • Add mappend syntax for SemiGroup and Monoid (#80)

    mappend syntax for SemiGroup and Monoid. append is too common name so there can be conflict in names with other types. So use mappend (short name for Monoid append) instead of append.

    1.mappend(2)
    // Int = 3
    
    "abc".mappend("def")
    // String = abcdef
    
    List(1, 2, 3).mappend(List(4, 5, 6))
    // List[Int] = List(1, 2, 3, 4, 5, 6)
  • Add OptionSemiGroup and OptionMonoid (#82)

    Add OptionSemiGroup to make Option[A] SemiGroup[A] and OptionMonoid to make Option[A] Monoid[A] if SemiGroup[A] exists.

    1.some |+| 999.some // Option[Int] = Some(1000)
    
    1.some.mappend(999.some) // Option[Int] = Some(1000)
    
    123.some |+| none[Int] // Option[Int] = Some(123)
    
    none[Int] |+| 999.some // Option[Int] = Some(999)
    
    List(1, 2, 3).some |+| List(4, 5, 6).some
    // Option[List[Int]] = Some(List(1, 2, 3, 4, 5, 6))
    
    List(1, 2, 3).some |+| none[List[Int]]
    // Option[List[Int]] = Some(List(1, 2, 3))
    
    none[List[Int]] |+| List(1, 2, 3).some
    // Option[List[Int]] = Some(List(1, 2, 3))

v1.2.0

21 Sep 13:54
af489ab
Compare
Choose a tag to compare

1.2.0 - 2019-09-21

Done

  • Replace ? with * (#68)

  • Change JustSyntax to syntax (#71)

    import just.fp.syntax._
  • Add OptionSyntax (#72)

    1.some // Option[Int] = Some(1)
    none[String] // Option[String] = None
  • Add toEither to OptionSyntax (#75)

    val maybeN = 1.some // Option[Int] = Some(1)
    maybeN.toEither("Something wrong") // Either[String, Int] = Right(1)
    
    val maybeN2 = none[Int] // Option[Int] = None
    maybeN2.toEither("Something wrong") // Either[String, Int] = Left("Something wrong")