承接 sixlive/parsedown-highlight 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

sixlive/parsedown-highlight

Composer 安装命令:

composer require sixlive/parsedown-highlight

包简介

Server side code block rendering for Parsedown

README 文档

README

NOTE: This requires v1.8 of Parsedown, which has not been released yet.

Packagist Version Packagist Downloads Travis Code Quality Code Coverage StyleCI

This extends Parsedown to add support for server side code block rendering. This uses scrivo/highlight.php to do all the code block rendering. This will be fully compatible with Highlight JS.

Installation

You can install the package via composer:

> composer require sixlive/parsedown-highlight

Usage

# Hello!

Here is a post with some code in it.

\```php
<?php

echo 'foo';
\```

\```asldfh
put 'WHOOP!'
\```
$parsedown = new \sixlive\ParsedownHighlight;

$parsedown->text(file_get_contents(__DIR__.'/README.md'));
<h1>Hello!</h1>
<p>Here is a post with some code in it.</p>
<pre><code class="language-php hljs php"><span class="hljs-meta">&lt;?php</span>

<span class="hljs-keyword">echo</span> <span class="hljs-string">'foo'</span>;</code></pre>
<pre><code class="language-asldfh">put 'WHOOP!'</code></pre>

Using Parsedown Extra

Note: This requires version 0.8.0-beta-1

$parsedown = new \sixlive\ParsedownHighlightExtra;

$parsedown->text(file_get_contents(__DIR__.'/README.md'));

Testing

> composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Code Style

In addition to the php-cs-fixer rules, StyleCI will apply the Laravel preset.

Linting

> composer styles:lint

Fixing

> composer styles:fix

Security

If you discover any security related issues, please email oss@tjmiller.co instead of using the issue tracker.

Credits

License

The MIT License (MIT). Please see License File for more information.

统计信息

  • 总下载量: 279
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 24
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 23
  • Watchers: 1
  • Forks: 4
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2018-11-06

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固