Ecosyste.ms: Packages

An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 4.1% on hackage.haskell.org
Top 9.1% downloads on hackage.haskell.org
Top 0.6% dependent packages on hackage.haskell.org
Top 5.2% dependent repos on hackage.haskell.org
Top 4.4% forks on hackage.haskell.org

hackage.haskell.org : relude

relude is an alternative prelude library. If you find the default Prelude unsatisfying, despite its advantages, consider using relude instead. Productivity. You can be more productive with a "non-standard" standard library, and relude helps you with writing safer and more efficient code faster. Total programming. Usage of <em>partial functions</em> can lead to unexpected bugs and runtime exceptions in pure code. The types of partial functions lie about their behaviour. And even if it is not always possible to rely only on total functions, relude strives to encourage best-practices and reduce the chances of introducing a bug. Type-safety. We use the "make invalid states unrepresentable" motto as one of our guiding principles. If it is possible, we express this concept through the types. Example: whenNotNull :: Applicative f => [a] -> (NonEmpty a -> f ()) -> f () Performance. We prefer Text over String, use space-leaks-free functions (e.g. our custom performant sum and product), introduce {-# INLINE #-} and {-# SPECIALIZE #-} pragmas where appropriate, and make efficient container types (e.g. Map, HashMap, Set) more accessible. Minimalism (low number of dependencies). We do not force users of relude to stick to any specific lens or text formatting or logging library. Where possible, relude depends only on boot libraries. The Dependency graph of relude can give you a clearer picture. Convenience. Despite minimalism, we want to bring commonly used types and functions into scope, and make available functions easier to use. Some examples of conveniences: No need to add containers, unordered-containers, text and bytestring to dependencies in your .cabal file to use the main API of these libraries No need to import types like NonEmpty, Text, Set, Reader[T], MVar, STM Functions like liftIO, fromMaybe, sortWith are available by default as well IO actions are lifted to MonadIO Excellent documentation. Tutorial Migration guide from Prelude Haddock for every function with examples tested by doctest. Documentation regarding internal module structure relude-specific HLint rules: .hlint.yaml User-friendliness. Anyone should be able to quickly migrate to relude. Only some basic familiarity with the common libraries like text and containers should be enough (but not necessary). Exploration. We have space to experiment with new ideas and proposals without introducing breaking changes. relude uses the approach with Extra.* modules which are not exported by default. The chosen approach makes it quite easy for us to provide new functionality without breaking anything and let the users decide to use it or not.

Registry - Source - JSON
purl: pkg:hackage/relude
Keywords: library, mit, prelude, alternative-prelude, haskell, safe, standard-library, user-friendly
License: MIT
Latest release: about 5 years ago
First release: almost 6 years ago
Dependent packages: 50
Dependent repositories: 120
Downloads: 16,809 total
Stars: 688 on GitHub
Forks: 80 on GitHub
Total Commits: 644
Committers: 70
Average commits per author: 9.2
Development Distribution Score (DDS): 0.689
More commit stats: commits.ecosyste.ms
See more repository details: repos.ecosyste.ms
Funding links: https://ko-fi.com/kowainik, https://github.com/sponsors/vrom911
Last synced: 5 days ago

    Loading...
    Readme
    Loading...