Sha256: f24b3a3ae34763fc97b3bce5ccd69ef23f4039a258276cdc046c73ae03913cf7

Contents?: true

Size: 543 Bytes

Versions: 4

Compression:

Stored size: 543 Bytes

Contents

# frozen_string_literal: true

class Asciidoctor::Document
  class << self
    def supports_syntax_highlighter?
      if @supports_syntax_highlighter.nil?
        # Asciidoctor only got pluggable syntax highlighters since 2.0:
        # https://github.com/asciidoctor/asciidoctor/commit/23ddbaed6818025cbe74365fec7e8101f34eadca
        @supports_syntax_highlighter = method_defined? :syntax_highlighter
      end

      @supports_syntax_highlighter
    end
  end

  def syntax_highlighter
    nil
  end unless supports_syntax_highlighter?
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
asciidoctor-epub3-1.5.1 lib/asciidoctor-epub3/ext/asciidoctor/document.rb
asciidoctor-epub3-1.5.0 lib/asciidoctor-epub3/ext/asciidoctor/document.rb
asciidoctor-epub3-1.5.0.alpha.19 lib/asciidoctor-epub3/ext/asciidoctor/document.rb
asciidoctor-epub3-1.5.0.alpha.18 lib/asciidoctor-epub3/ext/asciidoctor/document.rb