Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). Varbase Media Header 9.2.1 Minor update available for module varbase_media_header (9.2.1). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

This module provides a simple way to convert Markdown text into HTML using a text filter. It automatically sets up a "Markdown" text format upon installation, supporting various Markdown flavors like Standard, GitHub-flavored, and Markdown Smörgåsbord. For security, it's recommended to enable the "Limit allowed HTML tags" filter to run afterward.

The Markdown Easy module is a Drupal text filter to convert Markdown into HTML.

The primary use case for this module is to quickly and easily be able to configure and utilize a Markdown text filter. This module utilizes the league/commonmark Markdown parser library and allows for the bare minimum configuration in the Drupal admin interface.

It is required to utilize the "Limit allowed HTML tags and correct faulty HTML" text filters in conjunction with this module, see the Advanced configuration docs to remove this requirement.

Post-Installation

The Markdown Easy module automatically creates a "Markdown" text format when enabled. Feel free to customize.

To add a Markdown Easy text filter to an existing text format:

  • Select the "Markdown Easy" text filter.
  • Select "Standard Markdown", "GitHub-flavored Markdown", or "Markdown Smörgåsbord" in the text filter's settings on the text format's configuration page.
    • "Standard Markdown" includes support for italics, bold, images, links, lists, code, block quotes, headings, and horizontal rules.
    • "GitHub-flavored Markdown" includes everything in "Standard Markdown" plus support for autolinks, disallowed raw HTML, strikethrough, tables, and task lists. 
    • "Markdown Smörgåsbord" includes everything in "GitHub-flavored Markdown" plus support for footnotes and description lists.
  • IMPORTANT - Enable and configure the "Limit allowed HTML tags and correct faulty HTML" filter to run after the Markdown Easy filter. Without this step, the text format will allow all HTML tags.

Additional information

  • The Markdown Easy text filter is configured to run with the following security-related settings by default:
    • html_input: strip
    • allow_unsafe_links: false
  • See https://commonmark.thephpleague.com/2.4/security/ for more info. To override these settings, or to customize the configuration of the Markdown processor, utilize hook_markdown_easy_config_modify().
  • Note that the Markdown Easy module is currently not compatible with the Smart Trim module.

Warning: version 2.x includes a breaking change if you implemented hook_markdown_easy_config_modify() in version 1.x of this module - be sure to read the release notes for details.

Tip for migrating from Markdown module

  • The Markdown module allows the site-builder to install multiple Markdown processors, therefore, prior to installing Markdown Easy, if the league/commonmark parser is already installed, it should be removed (as Markdown Easy uses the latest version and Markdown does not).

    composer remove league/commonmark

Similar projects

Markdown - A less-easy, yet infinitely more configurable Markdown text filter.

Activity

Total releases
3
First release
Jun 2025
Latest release
11 months ago
Releases (12 mo)
2 ▲ from 1
Maintenance
Slowing

Release Timeline

Releases

Version Type Release date
2.0.0 Stable Aug 17, 2025
2.0.0-rc1 Pre-release Aug 4, 2025
2.0.x-dev Dev Jun 17, 2025