class

Crst::Config

Inherits Reference < Object

Configuration for parsing and rendering RST documents

Constructors

new(unsafe : Bool = false, tab_width : Int32 = 8, max_nesting_depth : Int32 = 100)
Source

Instance methods

admonition_classes

Custom CSS classes for admonitions

Source
admonition_classes=(admonition_classes : Hash(String, String))

Custom CSS classes for admonitions

Source
allowed_include_paths

Allowed paths for include directive (empty means allow all relative paths)

Source
allowed_include_paths=(allowed_include_paths : Array(String))

Allowed paths for include directive (empty means allow all relative paths)

Source
authors
Source
authors=(authors : Array(String))
Source
base_path

Base directory for resolving relative paths (include directive, etc.) Defaults to the current working directory at Config creation time.

Source
base_path=(base_path : String)

Base directory for resolving relative paths (include directive, etc.) Defaults to the current working directory at Config creation time.

Source
custom_directives

Custom directive handlers Proc takes: name, arguments, options, children, config -> Array(Node)

Source
custom_directives=(custom_directives : Hash(String, DirectiveHandler))

Custom directive handlers Proc takes: name, arguments, options, children, config -> Array(Node)

Source
date
Source
date=(date : String | Nil)
Source
encoding

Output encoding (default: "utf-8")

Source
encoding=(encoding : String)

Output encoding (default: "utf-8")

Source
language

Language for code blocks (default: nil, auto-detect)

Source
language=(language : String | Nil)

Language for code blocks (default: nil, auto-detect)

Source
max_nesting_depth

Maximum nesting depth to prevent stack overflow (default: 100)

Source
max_nesting_depth=(max_nesting_depth : Int32)

Maximum nesting depth to prevent stack overflow (default: 100)

Source
meta
Source
meta=(meta : Hash(String, String))
Source
roles

Custom role definitions

Source
roles=(roles : Hash(String, String))

Custom role definitions

Source
substitutions

Substitution definitions

Source
substitutions=(substitutions : Hash(String, Array(Crst::Node)))

Substitution definitions

Source
tab_width

Tab width for indentation (default: 8)

Source
tab_width=(tab_width : Int32)

Tab width for indentation (default: 8)

Source
title

Document metadata

Source
title=(title : String | Nil)

Document metadata

Source
unsafe=(unsafe : Bool)

Allow unsafe content (HTML pass-through, raw directives, etc.)

Source
unsafe?

Allow unsafe content (HTML pass-through, raw directives, etc.)

Source