2017 © Pedro Peláez
 

library renderer

A collection of different output renderers

image

kaloa/renderer

A collection of different output renderers

  • Sunday, October 8, 2017
  • by mermshaus
  • Repository
  • 1 Watchers
  • 4 Stars
  • 116 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

kaloa/renderer

Install

Via Composer:, (*1)

~~~ bash $ composer require kaloa/renderer, (*2)



## Requirements The following PHP versions are supported: - PHP 7.4 ## Documentation ### Usage ~~~ php use Kaloa\Renderer\Factory; $cm = Factory::createRenderer('commonmark'); echo $cm->render('**Hello *[World](http://example.org)*!**'); // <p><strong>Hello <em><a href="http://example.org">World</a></em>!</strong></p> $md = Factory::createRenderer('markdown'); echo $md->render('**Hello *[World](http://example.org)*!**'); // <p><strong>Hello <em><a href="http://example.org">World</a></em>!</strong></p> $bb = Factory::createRenderer('inigo'); echo $bb->render('[i]Hello [s]Moon[/s] [b]Earth[/b]![/i]'); // <p><em>Hello <s>Moon</s> <strong>Earth</strong>!</em></p> // ...

Renderers

commonmark (third-party)

The league/commonmark parser for CommonMark., (*3)

inigo

This is basically a BBCode renderer. The parser tries to automatically add <p> elements where appropriate. Therefore, all tags are classified as inline or outline., (*4)

Supported tags:, (*5)

  • i|em, b|strong
  • u, s|strike
  • icode
  • h1-h6
  • dl, dt, dd
  • ul, ol, li
  • table, tr, th, td
  • quote (=@author)
  • off|noparse
  • var
  • indent, center
  • url|link (=@href, @title)
  • img (=@src)
  • abbr (=@title)
  • html
  • code (=@lang)
  • fn, fnt
  • youtube

  • amazon

markdown (third-party)

The PHP Markdown parser (without extras)., (*6)

xml

todo, (*7)

xmllegacy

todo, (*8)

Testing

~~~ bash $ ./vendor/bin/phpunit, (*9)


Further quality assurance: ~~~ bash $ ./vendor/bin/phpcs --standard=PSR2 ./src $ ./vendor/bin/phpmd ./src text codesize,design,naming

Credits

License

The package is published under the MIT License. See LICENSE for full license info., (*10)

The Versions

08/10 2017

dev-master

9999999-dev http://kaloa.ermshaus.org/

A collection of different output renderers

  Sources   Download

MIT

The Requires

 

The Development Requires

xml output markdown bbcode renderer

18/11 2013

0.1.0

0.1.0.0 http://www.kaloa.org/

A collection of different output renderers

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

output renderer