retrospring/app/services/question_markdown.rb
2023-02-15 23:52:10 +01:00

14 lines
301 B
Ruby

# frozen_string_literal: true
require "uri"
class QuestionMarkdown < Redcarpet::Render::StripDown
include Rails.application.routes.url_helpers
include SharedMarkers
def paragraph(text) = "<p>#{text.gsub("\n", '<br>')}</p>"
def link(link, _title, _content)
process_link(link)
end
end