mo - Monads is a functional programming utility library for Go that introduces monads and related abstractions using modern Go generics. The project brings well-known FP constructs such as Option, Result, Either, Future, IO, and Task into the Go ecosystem to help developers write safer and more composable code. By leveraging generics introduced in Go 1.18+, the library provides strong type safety without relying on reflection or code generation. It is particularly useful for managing nullable values, error propagation, asynchronous workflows, and functional pipelines in a predictable way. The design draws inspiration from languages like Scala, Rust, and TypeScript FP libraries, making it familiar to developers with functional backgrounds. Overall, samber/mo enables a more declarative and expressive programming style in Go while remaining lightweight and dependency-free.

Features

  • Option Result and Either monads
  • Future and Task abstractions
  • IO and State functional utilities
  • Type-safe generics-based API
  • Functional composition helpers
  • No external dependencies

Project Samples

Project Activity

See All Activity >

Categories

Libraries

License

MIT License

Follow mo - Monads

mo - Monads Web Site

Other Useful Business Software
Stop Storing Third-Party Tokens in Your Database Icon
Stop Storing Third-Party Tokens in Your Database

Auth0 Token Vault handles secure token storage, exchange, and refresh for external providers so you don't have to build it yourself.

Rolling your own OAuth token storage can be a security liability. Token Vault securely stores access and refresh tokens from federated providers and handles exchange and renewal automatically. Connected accounts, refresh exchange, and privileged worker flows included.
Try Auth0 for Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of mo - Monads!

Additional Project Details

Programming Language

Go

Related Categories

Go Libraries

Registered

2026-02-20