How typelevel/cats works
Project type and purpose
• This is an open-source, multi-module Scala library (“Cats”) providing functional-programming abstractions (type classes, data types, laws, free structures, etc.) for Scala, Scala.js, and Scala Native.
• It is not a web or full-stack app—it’s a toolkit comprised of independent but inter-related modules.
File structure
• Top-level directories are modules:
• kernel / kernel-laws
• core / laws
• free
• algebra-core / algebra-laws
• alleycats-core / alleycats-laws
• cats-testkit
• bench, binCompatTest, scripts, scalafix, docs, tests
• Root has build.sbt, project/ (SBT meta-build), config files, CI workflows.
• Each module has src/main/scala and src/test/scala, often cross-built for Scala 2.12, 2.13+, 3, JS, JVM, Native.
README for additional insights
• Core modules: cats-kernel, cats-core, cats-free, cats-laws, cats-testkit, algebra, alleycats.
• Emphasis on modularity, binary compatibility, cross-platform support (Scala.js, Native).