A highly-extensible PHP Markdown parser that fully supports CommonMark and GitHub-Flavored Markdown specs.
league/commonmark is a PHP-based Markdown parser that converts Markdown text into HTML. It solves the need for a reliable, spec-compliant Markdown processor in PHP applications, ensuring consistent rendering across different platforms and implementations.
PHP developers building applications that require Markdown processing, such as content management systems, documentation generators, forums, or blogs. It's especially valuable for projects needing GitHub-style Markdown features.
Developers choose league/commonmark for its strict CommonMark and GFM compliance, extensibility through a robust extension system, and strong community support with integrations for major PHP frameworks.
Highly-extensible PHP Markdown parser which fully supports the CommonMark and GFM specs.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Fully implements CommonMark and GitHub-Flavored Markdown specs, ensuring consistent, predictable HTML output as emphasized in the README's philosophy.
Supports custom parsers, renderers, and extensions, with a rich ecosystem of community extensions for features like emojis or LaTeX rendering.
Includes options like 'html_input' and 'allow_unsafe_links' to strip unsafe HTML and disable dangerous links, with explicit warnings in the README for untrusted input.
Offers official integrations for Laravel, Symfony, Twig, and Drupal, reducing setup time for popular PHP projects.
Minor and patch releases can change HTML output due to bug fixes or spec updates, which might break visual consistency in applications relying on exact markup.
To safely allow raw HTML from untrusted sources, the README recommends external libraries like HTML Purifier, adding complexity to the security setup.
Only supports UTF-8 and ASCII encodings; Markdown in other encodings must be converted first, which can be a barrier for legacy systems.