• Stars
    star
    1,470
  • Rank 31,781 (Top 0.7 %)
  • Language
    TypeScript
  • License
    MIT License
  • Created over 7 years ago
  • Updated over 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A WYSIWYG Markdown Editor for browsers. Break the Wall between writing and previewing.

HyperMD

HyperMD Markdown Editor

Breaks the Wall between writing and preview, in a Markdown Editor.

NPM version Build Status

Online Demo | Examples | Documentation

中文介绍

Quickstart

// npm install --save hypermd codemirror
var HyperMD = require('hypermd')
var myTextarea = document.getElementById('input-area')
var editor = HyperMD.fromTextArea(myTextarea)

Remix on Glitch

Also for RequireJS, Parcel, webpack, plain browser env. Read the Doc

Why use HyperMD?

HyperMD is a set of CodeMirror add-ons / modes / themes / commands / keymap etc.

You may use both original CodeMirror and HyperMD on the same page.

🌈 Write, and preview on the fly

  • Regular Markdown blocks and elements
    • Strong, Emphasis, Strikethrough, Code
    • Links, Images
    • Title / Quote / Code Block / List / Horizontal Rule
  • Markdown Extension
    • Simple Table
    • Footnote 1
    • TODO List (the box is clickable)
    • YAML Front Matter
    • $\LaTeX$ Formula, inline or block display mode 2
    • Emoji: :joy: => 😂 (also support custom emoji)
  • And more
    • HTML in Markdown -- WYSIWIG MDX is possible
    • #hashtag support 3 , see demo
    • Flowchart and Diagrams (mermaid or flowchart.js)

💪 Better Markdown-ing Experience

  • Upload Images and files via clipboard, or drag'n'drop
  • Alt+Click to open link / jump to footnote 1
  • Hover to read footnotes
  • Copy and Paste, translate HTML into Markdown 4
  • Easy and ready-to-use Key-bindings (aka. KeyMap)

🎁 CodeMirror benefits

  • Syntax Highlight for code blocks, supports 120+ languages5. Mode can be loaded on-demand.
  • Configurable key-bindings
  • Diff and Merge
  • Themes 6
  • Almost all of CodeMirror addons!

🔨 Extensible and Customizable

🎹 Tailored KeyMap "HyperMD":

  • Table
    • Enter Create a table with | column | line |
    • Enter Insert new row, or finish a table (if last row is empty)
    • Tab or Shift-Tab to navigate between cells
  • List
    • Tab or Shift-Tab to indent/unindent current list item
  • Formatting a nearby word (or selected text)
    • Ctrl+B bold
    • Ctrl+I emphasis
    • Ctrl+D strikethrough

Special Thanks

💎 Service and Resource

IcoMoon - The IconPack(Free Version)
Demo Page uses IcoMoon icons. Related files are stored in demo/svgicon.
CodeCogs - An Open Source Scientific Library
FoldMath uses codecogs' service as the default TeX MathRenderer.
(You may load PowerPack to use other renderer, eg. KaTeX or MathJax)
SM.MS - A Free Image Hosting service
Demo Page and PowerPack/insert-file-with-smms use SM.MS open API to upload user-inserted images.
(If you want to integrate SM.MS service, use the PowerPack)
EmojiOne - Open emoji icons
Demo Page and PowerPack/fold-emoji-with-emojione use Emoji icons provided free by EmojiOne (free license)
(You may use other alternatives, eg. twemoji from twitter)
CodeMirror - In-browser code editor.
RequireJS - A JavaScript AMD module loader.
KaTeX - The fastest math typesetting library for the web.
marked, turndown and more remarkable libs.

🌟 Sponsors

🙏 Sponsors (sorted by date)

Phithon c*i *Yuan ☕*Xiuzhang *Junjie 🌟圆伞科技 *Di

Contributing

HyperMD is a personal Open-Source project by laobubu. Contributions are welcomed. You may:


Footnotes

  1. Ctrl+Click works too, but will jump to the footnote if exists. 2

  2. Math block use $$ to wrap your TeX expression.

  3. Disabled by default, see doc; #use two hash symbol# if tag name contains spaces.

  4. Use Ctrl+Shift+V to paste plain text.

  5. Languages as many as CodeMirror supports.

  6. If the theme is not designed for HyperMD, some features might not be present.

More Repositories

1

MarkdownIME

A fresh way to write well-formatted text, by typing markdownized stuff on web.
TypeScript
469
star
2

jekyll-theme-EasyBook

Another Jekyll Blog Theme "EasyBook"
CSS
121
star
3

ssland

A lightweight Shadowsocks multi-user web-frontend panel.
Python
97
star
4

QRScaner

A QR Code scanner extension for Firefox.
JavaScript
47
star
5

openshift-php5.5-cgi-apache

QuickStart for fully free OpenShift + PHP5.5 + Apache
Shell
25
star
6

youtube-index

a wonderful PHP YouTube proxy
PHP
14
star
7

PuTTY

Another modified PuTTY.
C
12
star
8

Chrome-WebSocket-Notification-Extension-Example

Chrome WebSocket Notification Extension Example
JavaScript
12
star
9

STM32-Voice-Changer

A Real-time Voice Changer based on SensorTile (STM32L4).
C
11
star
10

HostsGenerator

A PHP Web util designed to generate Hosts file
PHP
7
star
11

sensor-android

An app which fetch sensor's data and share with other devices via UDP
Java
5
star
12

SynapticsPen

Just another Synaptics SDK test
C++
5
star
13

typecho_ContentIndex

一个为 Typecho 文章单页生成内容目录的插件。
PHP
4
star
14

ezStruct

Easiest way to pack/unpack struct data with three steps in Node.js.
JavaScript
4
star
15

BFlight

A dummy flight firmware based on STM32CubeMX HAL Driver
C
3
star
16

UpperMachine

Flexible Serial Port App for Windows
C#
2
star
17

laobubu.github.io

laobubu.net website
HTML
2
star
18

laobubu.blog

Well, Do Not Care.
HTML
2
star
19

WinMate

Make any window on top, transparent etc.
C++
2
star
20

DropBox-API-For-PHP

DropBox-API For PHP. No special module and mode required.
1
star
21

lite-dev

Lightweight development server and compiler.
JavaScript
1
star
22

PHP-AJAX-Terminal

A good PHP AJAX Terminal for programmers who want to do shell and eval php code
1
star
23

laobubu-strange-stuffs

Strange Stuffs
PHP
1
star
24

pico_WebServlet_temple_for_eclipse

直接导入Eclipse不需要J2EE就可以进行Java Web编程了!
Java
1
star
25

typecho_RewriteRule

使 Typecho 在 404 时可以遵循设定的规则,重定向到其他地址上。
PHP
1
star