diff --git a/Gemfile b/Gemfile index ea7e26c4..210babc3 100644 --- a/Gemfile +++ b/Gemfile @@ -29,7 +29,7 @@ group :docs do gem "filewatcher" gem "htmlbeautifier" gem "redcarpet" - gem "commonmarker", "~> 0.23" + gem "markly" gem "webrick" gem "rouge" gem "kramdown" diff --git a/lib/phlex.rb b/lib/phlex.rb index c603d095..c6d1262a 100644 --- a/lib/phlex.rb +++ b/lib/phlex.rb @@ -10,6 +10,7 @@ module Phlex loader.ignore("#{__dir__}/install") loader.ignore("#{__dir__}/phlex/testing") + loader.ignore("#{__dir__}/phlex/markdown") loader.ignore("#{__dir__}/phlex/rails.rb") loader.ignore("#{__dir__}/phlex/rails") diff --git a/lib/phlex/markdown.rb b/lib/phlex/markdown.rb index 20fc82b0..98a8a67f 100644 --- a/lib/phlex/markdown.rb +++ b/lib/phlex/markdown.rb @@ -1,6 +1,6 @@ # frozen_string_literal: true -require "commonmarker" +require "markly" module Phlex class Markdown < Phlex::HTML @@ -15,7 +15,7 @@ def template private def doc - CommonMarker.render_doc(@content) + Markly.parse(@content) end def visit(node)