All Projects → adhocore → htmlup

adhocore / htmlup

Licence: MIT license
light and fast markdown parser

Programming Languages

PHP
23972 projects - #3 most used programming language

Projects that are alternatives of or similar to htmlup

Flexmark Java
CommonMark/Markdown Java parser with source level AST. CommonMark 0.28, emulation of: pegdown, kramdown, markdown.pl, MultiMarkdown. With HTML to MD, MD to PDF, MD to DOCX conversion modules.
Stars: ✭ 1,673 (+3385.42%)
Mutual labels:  markdown-parser, markdown-to-html
Markdig
A fast, powerful, CommonMark compliant, extensible Markdown processor for .NET
Stars: ✭ 2,730 (+5587.5%)
Mutual labels:  markdown-parser, markdown-to-html
Markdown
A Python implementation of John Gruber’s Markdown with Extension support.
Stars: ✭ 2,725 (+5577.08%)
Mutual labels:  markdown-parser, markdown-to-html
Markdown-for-Documentation
Markdown is a HTML compatible language used for Documentation.
Stars: ✭ 14 (-70.83%)
Mutual labels:  markdown-parser, markdown-to-html
Markitdown
📱 A React app to preview and edit Markdown✍. You can also export it as HTML.
Stars: ✭ 26 (-45.83%)
Mutual labels:  markdown-parser, markdown-to-html
Mditor
📝 [ M ] arkdown + E [ ditor ] = Mditor
Stars: ✭ 523 (+989.58%)
Mutual labels:  markdown-parser, markdown-to-html
markdown articles tool
Parse markdown article, download images and replace images URL's with local paths
Stars: ✭ 37 (-22.92%)
Mutual labels:  markdown-parser, markdown-to-html
Markdown
A super fast, highly extensible markdown parser for PHP
Stars: ✭ 945 (+1868.75%)
Mutual labels:  markdown-parser, markdown-to-html
Mdtool
A tool which can process markdown to HTML
Stars: ✭ 136 (+183.33%)
Mutual labels:  markdown-parser, markdown-to-html
ModooCode
Repo for the Modoocode.
Stars: ✭ 42 (-12.5%)
Mutual labels:  markdown-parser
html2text
Convert HTML to Markdown-formatted text.
Stars: ✭ 1,351 (+2714.58%)
Mutual labels:  markdown-parser
Frontyaml
YAML Front matter parser
Stars: ✭ 248 (+416.67%)
Mutual labels:  markdown-parser
Markdown-Crash-Course
Markdown Crash Course. Learn Markdown language on a simple way.
Stars: ✭ 100 (+108.33%)
Mutual labels:  markdown-to-html
madness
Instant Markdown Server
Stars: ✭ 54 (+12.5%)
Mutual labels:  markdown-to-html
readmesfix
Because I'm tired of running into broken READMEs!
Stars: ✭ 63 (+31.25%)
Mutual labels:  markdown-parser
Parsedown
Better Markdown Parser in PHP
Stars: ✭ 13,959 (+28981.25%)
Mutual labels:  markdown-parser
Mizi
A simple markdown to website generator written in C++.
Stars: ✭ 31 (-35.42%)
Mutual labels:  markdown-to-html
xkeditor
📝 XK-Editor | 一个支持富文本和Markdown的编辑器
Stars: ✭ 58 (+20.83%)
Mutual labels:  markdown-to-html
parcel-plugin-markdown-string
📦@parcel-bundler plugin for loader markdown string, markdown output HTML.
Stars: ✭ 19 (-60.42%)
Mutual labels:  markdown-to-html
markdown nav
markdown自动生成导航目录
Stars: ✭ 48 (+0%)
Mutual labels:  markdown-to-html

adhocore/htmlup

Latest Version Travis Build Scrutinizer CI Codecov branch StyleCI Software License Donate 15 Donate 25 Donate 50 Tweet

htmlup is ultra lightweight and uber speedy markdown to html parser written in PHP. Concept - it splits the markdown into lines and parses to markup one by one, finally applies markdown syntaxes on the markup. It supports most of the markdown as in specs.

installation

Run composer require adhocore/htmlup

usage

<?php

use Ahc\HtmlUp;

// require '/path/to/vendor/autoload.php';

// Defaults to 4 space indentation.
echo new Ahc\HtmlUp($markdownText);

// Force 2 space indentation.
echo new HtmlUp($markdownText, 2);

// Also possible:
echo (new Htmlup)->parse($markdownText);

features

nesting

It provides limited support to deep nested elements, supported items are:

  • lists inside lists
  • blockquotes inside blockcodes
  • lists inside blockquotes

raw html

you can throw in your raw html but with a blank line at start and end to delimit the block at like so-

<dl>
  <dt>
  	A
  </dt>
  <dd>Apple
  	</dd>
  	<dt>B
  </dt>
  <dd>
  Ball</dd>
</dl>

table

supports GFM table syntax, example:

a | b | c
--- |----| ---
1 | 2  |3
 4| 5 | 6

is rendered as:

a b c
1 2 3
4 5 6

todo

  • make robust, and provide full support of spec
  • handle markdown table syntax
  • markdown extra however, is not planned :(

contributing

  • fork and pull request for patch/fix
  • create issue for breaking bugs and severe markdown spec violation
  • please check the guide

license

© 2014-2018 | Jitendra Adhikari | MIT

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].