uhi67/showdown

Markdown converter module for Yii2

Installs: 183

Dependents: 0

Suggesters: 0

Security: 0

Stars: 1

Watchers: 2

Forks: 0

Open Issues: 0

Language:JavaScript

Type:yii2-extension

1.2.2 2021-10-04 13:14 UTC

This package is auto-updated.

Last update: 2024-03-04 18:54:25 UTC


README

Showdown.js interface for Yii2

Version 1.2.2 -- release 2021-10-04

Based on https://github.com/showdownjs version 1.7.1

Detailed documentation of showdownjs

Installation

The preferred way to install this extension is through composer.

To install, either run

composer require uhi67/showdown "^1.2" 

or add

"uhi67/showdown" : "^1.2"

or clone form github

git clone https://github.com/uhi67/showdown

Usage

in the view

<?php
	// ...
	uhi67\showdown\ShowdownAsset::register($this); // or put this into the global layout
?>
<div class="showdown">
	<pre class="markdown"><?= $content ?></pre>
</div>	

where $content is the markdown content readed from your .md file.

Change log

1.2.2 -- 2021-10-04

  • Removed unnecessary trace

1.2.1 -- 2021-02-03

  • Replaces "--" (double hyphen) to mdash character

1.2 -- 2020-12-22

  • if .simple class is used in pre.markdown, will not render links and images

1.1 -- 2020-04-21

  • simpleLineBreaks option changed to false -- now ignores simple line breaks in source