How to invoke the Pandoc API for markdown conversion in Haskell ghci

Source: Internet
Author: User
Tags command line

Environment used: Windows Server 2008 + GHC 7.6.3 (Haskell Platform 2013.2.0.0 Self-band) + Pandoc 1.12.4

Operation Steps:

1. Install Haskell Platform, download address: http://www.haskell.org/platform/.

2. Install pandoc, install command: Cabal install Pandoc

3. Run ghci on the command line

4. Refer to the corresponding module of Pandoc and run at the Prelude command prompt:

: module Text.pandoc Text.Pandoc.Readers.Markdown Text.Pandoc.Writers.HTML

5. Call the Pandoc Readmarkdown and the writehtmlstring function for markdown conversion to HTML:

 

The results of the operation are as follows:

Back to the column page: http://www.bianceng.cnhttp://www.bianceng.cn/Programming/extra/

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.