Skip to content

Commit

Permalink
Configure Zeitwerk to ignore Markdown
Browse files Browse the repository at this point in the history
The markdown view has an optional dependency so should be ignored by default.
  • Loading branch information
joeldrapper committed Nov 16, 2022
1 parent 16edeba commit 56fbad0
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
1 change: 1 addition & 0 deletions lib/phlex.rb
Original file line number Diff line number Diff line change
Expand Up @@ -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")
Expand Down
4 changes: 2 additions & 2 deletions lib/phlex/markdown.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# frozen_string_literal: true

require "commonmarker"
require "markly"

module Phlex
class Markdown < Phlex::HTML
Expand All @@ -15,7 +15,7 @@ def template
private

def doc
CommonMarker.render_doc(@content)
Markly.parse(@content)
end

def visit(node)
Expand Down

0 comments on commit 56fbad0

Please sign in to comment.