Class: Slideck::Converter Private
- Inherits:
-
Object
- Object
- Slideck::Converter
- Defined in:
- lib/slideck/converter.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Responsible for converting Markdown into terminal output
Instance Method Summary collapse
-
#convert(content, symbols: nil, theme: nil, width: nil) ⇒ String
Convert content into terminal output.
-
#initialize(markdown_parser, color: nil) ⇒ Converter
constructor
Create a Converter instance.
Constructor Details
#initialize(markdown_parser, color: nil) ⇒ Converter
Create a Converter instance
27 28 29 30 |
# File 'lib/slideck/converter.rb', line 27 def initialize(markdown_parser, color: nil) @markdown_parser = markdown_parser @color = validate_color(color) end |
Instance Method Details
#convert(content, symbols: nil, theme: nil, width: nil) ⇒ String
Convert content into terminal output
49 50 51 52 |
# File 'lib/slideck/converter.rb', line 49 def convert(content, symbols: nil, theme: nil, width: nil) @markdown_parser.parse( content, color: @color, symbols: symbols, theme: theme, width: width) end |