2017 © Pedro Peláez
 

library silex-markdown

A lightweight markdown service provider for Silex

image

bretrzaun/silex-markdown

A lightweight markdown service provider for Silex

  • Saturday, February 4, 2017
  • by bretrzaun
  • Repository
  • 1 Watchers
  • 0 Stars
  • 96 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 5 Forks
  • 0 Open issues
  • 5 Versions
  • 0 % Grown

The README.md

Silex-Markdown

Build Status Scrutinizer Code Quality, (*1)

A lightweight markdown service provider for Silex. Uses the michelf/php-markdown markdown parser., (*2)

Based on: nicl/silex-markdown, (*3)

Installation

Recommended installation is through composer. Just add the following to your composer.json file:, (*4)

{
    "require": {
        "bretrzaun/silex-markdown": "^1.0"
    }
}

Usage

To use the service provider first register it:, (*5)

$app->register(new MarkdownServiceProvider());

You can then use the markdown filter in Twig files. For example:, (*6)

{{ '#Hello World'|markdown }}

In addition, you also have access to the Markdown parser itself. Simply instantiate it and call the transform method as follows:, (*7)

$app['markdown']->transform($txt);

Configuration

Parameters

  • markdown.factory: Name of the service that will create Michelf\MarkdownInterface instances, string.
  • markdown.parser: Name of the built-in parser to use, string. Default: markdown, (*8)

    Available options:, (*9)

    • markdown: Standard Markdown parser
    • extra: Markdown Extra parser

Services

  • markdown: Markdown parser, instance of Michelf\MarkdownInterface.

Tests

If you wish to run the tests then, from the silex-markdown root directory run:, (*10)

composer test

The Versions

04/02 2017

dev-master

9999999-dev http://github.com/bretrzaun/silex-markdown

A lightweight markdown service provider for Silex

  Sources   Download

MIT

The Requires

 

The Development Requires

by Bret R. Zaun

silex markdown

04/02 2017

2.0.0

2.0.0.0 http://github.com/bretrzaun/silex-markdown

A lightweight markdown service provider for Silex

  Sources   Download

MIT

The Requires

 

The Development Requires

by Bret R. Zaun

silex markdown

14/03 2016

1.2.0

1.2.0.0 http://github.com/bretrzaun/silex-markdown

Simple Silex wrapper for markdown library

  Sources   Download

MIT

The Requires

 

The Development Requires

by Bret R. Zaun

markdown

05/08 2013

1.1.0

1.1.0.0 http://github.com/nicl/silex-markdown

Simple Silex wrapper for the Dragonfly markdown library

  Sources   Download

MIT

The Requires

 

by Nicolas Long

markdown

16/10 2012

1.0.0

1.0.0.0 http://github.com/nicl/silex-markdown

Simple Silex wrapper for the Dragonfly markdown library

  Sources   Download

The Requires

 

by Nicolas Long

markdown