GitHub - iamgio/quarkdown: 🪐 Markdown with superpowers — from ideas to presentations, articles and books. (original) (raw)


Table of contents

  1. About
  2. Demo
  3. Targets
  4. Comparison
  5. Getting started
    1. Installation
    2. Creating a project
    3. Compiling
  6. Mock document
  7. Contributing
  8. Sponsors
  9. Concept

About

Quarkdown is a modern Markdown-based typesetting system, designed around the key concept of versatility, by seamlessly compiling a project into a print-ready book or an interactive presentation. All through an incredibly powerful Turing-complete extension of Markdown, ensuring your ideas flow automatically into paper.

Paper demo

Original credits: Attention Is All You Need

Born as an extension of CommonMark and GFM, the Quarkdown Flavor brings functions to Markdown, along with many other syntax extensions.

This is a function call:

.somefunction {arg1} {arg2}
   Body argument

Possibilities are unlimited thanks to an ever-expanding standard library, which offers layout builders, I/O, math, conditional statements and loops.

Not enough? You can still define your own functions and variables — all within Markdown. You can even create awesome libraries for everyone to use.

.function {greet}
   to from:
   **Hello, .to** from .from!

.greet {world} from:{iamgio}

Result: Hello, world from iamgio!

This out-of-the-box scripting support opens doors to complex and dynamic content that would be otherwise impossible to achieve with vanilla Markdown.

Combined with live preview and ⚡ fast compilation speed, Quarkdown simply gets the work done.

Live preview

Check the wiki to learn more about the language and its features.


Check out the demo presentation here

Built with Quarkdown itself — source code

(Desktop view is suggested)


As simple as you expect...

Paper code demo

Inspired by: X-ray flashes from a nearby supermassive black hole accelerate mysteriously

...as complex as you need.

Chart code demo

Targets

The desired document type can be set by calling the .doctype function within the source itself:

Comparison

Quarkdown Markdown LaTeX Typst AsciiDoc MDX
Concise and readable
Full document control
Scripting Partial
Book/article export Third-party
Presentation export Third-party
Learning curve 🟢 🟢 🔴 🟠 🟢 🟢
Targets HTML, PDF HTML PDF, PostScript PDF HTML, PDF, ePub HTML
LaTeX Quarkdown
\tableofcontents \section{Section} \subsection{Subsection} \begin{enumerate} \item \textbf{First} item \item \textbf{Second} item \end{itemize} \begin{center} This text is \textit{centered}. \end{center} \begin{figure}[!h] \centering \begin{subfigure}[b] \includegraphics[width=0.3\linewidth]{img1.png} \end{subfigure} \begin{subfigure}[b] \includegraphics[width=0.3\linewidth]{img2.png} \end{subfigure} \begin{subfigure}[b] \includegraphics[width=0.3\linewidth]{img3.png} \end{subfigure} \end{figure} .tableofcontents # Section ## Subsection 1. **First** item 2. **Second** item .center This text is _centered_. .row alignment:{spacebetween} ![Image 1](img1.png) ![Image 2](img2.png) ![Image 3](img3.png)

Getting started

Installation

Download quarkdown.zip from the latest stable release or build it with gradlew distZip, and unzip it.

Java 17 or higher is required. All major operating systems are supported.

Creating a project

Running quarkdown create [directory] will launch the prompt-based project wizard, making it quicker than ever to set up a new Quarkdown project, with all metadata and initial content already present.

For more information about the project creator, check out its wiki page.

Alternatively, you may manually create a .qmd source file and start from there.

Compiling

Running quarkdown c file.qmd will compile the given file and save the output to file.

If the project is composed by multiple source files, the target file must be the root one, i.e. the one that includes the other files.

If you would like to familiarize yourself with Quarkdown instead, quarkdown repl lets you play with an interactive REPL mode.

Options

Tip

Combine -p -w to achieve live preview!


Mock document

Mock document demo

Mock, written in Quarkdown, is a comprehensive collection of visual elements offered by the language, making it ideal for exploring and understanding its key features — all while playing and experimenting hands-on with a concrete outcome in the form of pages or slides.

Contributing

Contributions are welcome! Please check CONTRIBUTING.md to know how contribute via issues or pull requests.

Sponsors

A special thanks to all the sponsors who supported this project!

LunaBluee dcopia Pallandos

Concept

The logo resembles the original Markdown icon, with focus on Quarkdown's completeness, richness of features and customization options, emphasized by the revolving arrow all around the sphere.

Quarkdown icon

What could be mistaken for a planet is actually a quark or, more specifically, a down quark, an elementary particle that is a major constituent of matter: they give life to every complex structure we know of, while also being one of the lightest objects in existence.

This is, indeed, the concept Quarkdown is built upon.