1
0
mirror of https://github.com/flextype/flextype.git synced 2025-08-08 22:26:46 +02:00

feat(markdown): add markdown basic settings #471

This commit is contained in:
Awilum
2020-09-07 12:50:46 +03:00
parent e6665ad04b
commit 1cdf21aa83
2 changed files with 14 additions and 0 deletions

View File

@@ -222,6 +222,10 @@ flextype()->container()['markdown'] = static function () {
return new Markdown(new ParsedownExtra());
};
flextype('markdown')->getInstance()->setBreaksEnabled(flextype('registry')->get('flextype.settings.markdown.auto_line_breaks'));
flextype('markdown')->getInstance()->setUrlsLinked(flextype('registry')->get('flextype.settings.markdown.auto_url_links'));
flextype('markdown')->getInstance()->setMarkupEscaped(flextype('registry')->get('flextype.settings.markdown.escape_markup'));
/**
* Add json serializer service to Flextype container
*/

View File

@@ -323,6 +323,16 @@ slugify:
image:
driver: gd
# Markdown
#
# - markdown.auto_line_breaks: Enable automatic line breaks
# - markdown.auto_url_links: Enable automatic HTML links
# - markdown.escape_markup: Escape markup tags into entities
markdown:
auto_line_breaks: false
auto_url_links: false
escape_markup: false
# Shortcode
#
# - shortcodes: Flextype Shortcodes to load.