Welcome to mirror list, hosted at ThFree Co, Russian Federation.

plain_markdown_pipeline.rb « pipeline « banzai « lib - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 205bbc2140d568c62935db471fdb6cf61987c0ba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
# frozen_string_literal: true

module Banzai
  module Pipeline
    class PlainMarkdownPipeline < BasePipeline
      # DollarMathPreFilter and DollarMathPostFilter need to be included here,
      # rather than in another pipeline.  However, since dollar math would most
      # likely be supported as an extension in any other markdown parser we used,
      # it is not out of place.  We are considering this a part of the actual
      # markdown processing
      def self.filters
        FilterArray[
          Filter::MarkdownPreEscapeFilter,
          Filter::DollarMathPreFilter,
          Filter::MarkdownFilter,
          Filter::DollarMathPostFilter,
          Filter::MarkdownPostEscapeFilter
        ]
      end
    end
  end
end