Sha256: 8a9b6e4a29929fa805c31be9a23008532e8710c08e4d7a8dae844a7926009387
Contents?: true
Size: 923 Bytes
Versions: 8
Compression:
Stored size: 923 Bytes
Contents
begin require "redcloth" rescue LoadError => _ raise HTML::Pipeline::MissingDependencyError, "Missing dependency 'RedCloth' for TextileFilter. See README.md for details." end module HTML class Pipeline # HTML Filter that converts Textile text into HTML and converts into a # DocumentFragment. This is different from most filters in that it can take a # non-HTML as input. It must be used as the first filter in a pipeline. # # Context options: # :autolink => false Disable autolinking URLs # # This filter does not write any additional information to the context hash. # # NOTE This filter is provided for really old comments only. It probably # shouldn't be used for anything new. class TextileFilter < TextFilter # Convert Textile to HTML and convert into a DocumentFragment. def call RedCloth.new(@text).to_html end end end end
Version data entries
8 entries across 8 versions & 1 rubygems