GithubHelp home page GithubHelp logo

concisemark's Introduction

ConciseMark (documentation)

ConciseMark is a simplified markdown parsing library written in Rust with customization, math supporting in mind. The simplified here means it only supports some common markdown syntax but not full. For Chinese introduction, please click ConciseMark 中文介绍.

Features

  • Basic

    • Emphasis

      Use *Itaclics* to write itaclic text.

      Use **Itaclics** to write bold text.

    • Paragraph

      A paragraph consists of a sequence lines without empty line between them.

    • Heading

      Use #, ##, ... ###### to indicate one to six level heading.

      # must be the first character in your heading line.

      As a thumb of rule, you should avoid heading level greating than three.

    • Blockquote

      A blockquote is paragraph starts with > symbol, and > must be the first character of the paragraph, for example

        > a simple blockquote
        with very *long* body
        **really long** body ...
      

      If you want to show empty line in blockquote, you can do like the following

        > a simple line
        >
        > line
        test
      
    • List

      Use - to indicate a list item, nested list is also supported.

      Indentation between two adjacent lists must be 4.

      Numbered list is not supported yet.

    • Link && Image

      Use [google](https://google.com) to dispaly a link.

      Use ![image](https://example.com/some.jpg) to dispaly an image.

    • Code

      Use backtick (`) pair to show inline mode code.

      Indent your code in a new paragraph with indention more than four spaces than your current indention, then it will be dispaly mode.

  • Extension

    • Math

      Math in HTML is supported by katex or mathjax, use one syntax such as $a^2 + b^2$ to write math equation.

      If $a^2 + b^2$ is in paragraph, then it will be inline mode (generated text will be $a^2 + b^2$).

      If $a^2 + b^2$ holds the full paragraph, then it will be display mode (rendered text will be $$a^2 + b^2$$).

      Note that this library does not bundle katex or mathjax, you must import katex or mathjax in your generated html file.

    • Latex PDF Generation

      ConciseMark supports you to convert your markdown into xelatex source file, then you can compile it with xelatex command to generate a pretty PDF document.

      Note that to make the generated xelatex source compilable, you have to install the following fonts onto your system

    • Markdown Meta

      You can put an optional html comment (whose body is in toml format) in the front of your markdown file

        <!---
        title = "Your title"
        subtitle = "Your subtitle"
        date = "2021-10-13 00:00:00"
        authors = ["name <[email protected]>"]
        tags = ["demo", "example"]
        -->
      

      This content will be parsed as your page meta, you can use it when rendering latex or html page.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.