Sha256: 155838a92e5658f899acadf0aef229922a483227d5041f223fa6f40d0ee518b7
Contents?: true
Size: 574 Bytes
Versions: 11
Compression:
Stored size: 574 Bytes
Contents
# frozen_string_literal: true require "asciidoctor" module Milestoner module Renderers # Renders ASCII Doc as HTML. class Asciidoc SETTINGS = { safe: :safe, attributes: { "source-highlighter" => "rouge", "rouge-linenums-mode" => "inline" } }.freeze def initialize settings: SETTINGS, client: Asciidoctor @settings = settings @client = client end def call(content) = client.convert content, settings private attr_reader :settings, :client end end end
Version data entries
11 entries across 11 versions & 1 rubygems