serokell-util-0.1.2.4: General-purpose functions by Serokell

Safe HaskellNone
LanguageHaskell2010

Serokell.Util.I18N

Contents

Documentation

type Translations lang token = Map lang (Map token Text) Source #

fromYaml :: (YamlMapKey lang, YamlMapKey token) => ByteString -> Translations lang token Source #

replaceTranslations :: (ToReplaceToken token, Ord lang) => Translations lang token -> lang -> Text -> Maybe Text Source #

class (Eq a, Ord a, FromJSONKey a) => YamlMapKey a Source #

Instances

(Eq a, Ord a, Generic a, GFromJSON (Rep a)) => YamlMapKey a Source # 

class (Ord a, Eq a) => ToReplaceToken a where Source #

Minimal complete definition

toReplaceToken

Methods

toReplaceToken :: a -> Text Source #

Instances

(Ord a, Eq a, Generic a, GToJSON (Rep a)) => ToReplaceToken a Source # 

Methods

toReplaceToken :: a -> Text Source #

Orphan instances

(Generic a, GFromJSON (Rep a)) => FromJSONKey a Source # 

Methods

parseJSONKey :: Text -> Parser a #