Safe Haskell | None |
---|---|
Language | Haskell2010 |
Helpers for working with Pandoc documents
Synopsis
- parse :: (ReaderOptions -> Text -> PandocIO Pandoc) -> Path Rel File -> Action Pandoc
- parsePure :: (ReaderOptions -> Text -> PandocPure Pandoc) -> Text -> Pandoc
- render :: Monad m => Pandoc -> HtmlT m ()
- renderPandocInlines :: Monad m => [Inline] -> HtmlT m ()
- extractMeta :: Pandoc -> Maybe (Either Text Value)
- getH1 :: Monad m => Pandoc -> Maybe (HtmlT m ())
- getToC :: Monad m => Pandoc -> HtmlT m ()
- getFirstImg :: Pandoc -> Maybe Text
- data Pandoc
- module Text.Pandoc.Readers
Parsing
:: (ReaderOptions -> Text -> PandocIO Pandoc) | The pandoc text reader function to use, eg: |
-> Path Rel File | |
-> Action Pandoc |
Parse a lightweight markup language using Pandoc
parsePure :: (ReaderOptions -> Text -> PandocPure Pandoc) -> Text -> Pandoc Source #
Pure version of parse
Rendering
Extracting information
extractMeta :: Pandoc -> Maybe (Either Text Value) Source #
Extract the Pandoc metadata as JSON value
Get the first image in the document if one exists
Re-exports
Instances
Eq Pandoc | |
Data Pandoc | |
Defined in Text.Pandoc.Definition gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Pandoc -> c Pandoc # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Pandoc # toConstr :: Pandoc -> Constr # dataTypeOf :: Pandoc -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Pandoc) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Pandoc) # gmapT :: (forall b. Data b => b -> b) -> Pandoc -> Pandoc # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Pandoc -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Pandoc -> r # gmapQ :: (forall d. Data d => d -> u) -> Pandoc -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> Pandoc -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> Pandoc -> m Pandoc # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Pandoc -> m Pandoc # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Pandoc -> m Pandoc # | |
Ord Pandoc | |
Read Pandoc | |
Show Pandoc | |
Generic Pandoc | |
Semigroup Pandoc | |
Monoid Pandoc | |
NFData Pandoc | |
Defined in Text.Pandoc.Definition | |
ToJSON Pandoc | |
Defined in Text.Pandoc.Definition | |
FromJSON Pandoc | |
HasMeta Pandoc | |
Defined in Text.Pandoc.Builder | |
Walkable Block Pandoc | |
Walkable Inline Pandoc | |
Walkable Pandoc Pandoc | |
Walkable [Block] Pandoc | |
Walkable [Inline] Pandoc | |
type Rep Pandoc | |
Defined in Text.Pandoc.Definition type Rep Pandoc = D1 (MetaData "Pandoc" "Text.Pandoc.Definition" "pandoc-types-1.20-lzfUc8G4Y8IiRaWHrGIBP" False) (C1 (MetaCons "Pandoc" PrefixI False) (S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Meta) :*: S1 (MetaSel (Nothing :: Maybe Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Block]))) |
module Text.Pandoc.Readers