Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- with :: Components a names apis => Component name api -> a -> ComponentList (name ': names) ((name :> api) :<|> apis)
- class ToServantAPI names apis => Components a (names :: [Symbol]) apis | a -> names apis where
- serveAll' :: a -> Server apis
- describe :: a -> [ComponentDescription]
Documentation
with :: Components a names apis => Component name api -> a -> ComponentList (name ': names) ((name :> api) :<|> apis) infixr 9 Source #
Compose Components
This function combines a Component
with another Component
,
or with a ComponentList
, producing a ComponentList
.
It collects the names of the components, and keeps the expected API structure.
class ToServantAPI names apis => Components a (names :: [Symbol]) apis | a -> names apis where Source #
Instances
ToServantAPI names apis => Components (ComponentList names apis) names apis Source # | |
Defined in Admin.Components.ComponentsClass serveAll' :: ComponentList names apis -> Server apis Source # describe :: ComponentList names apis -> [ComponentDescription] Source # | |
(KnownSymbol name, HasServer api ('[] :: [Type])) => Components (Component name api) '[name] (name :> api) Source # | |