承接 hollodotme/treemdown-multi 相关项目开发

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

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

hollodotme/treemdown-multi

Composer 安装命令:

composer require hollodotme/treemdown-multi

包简介

A PHP class for browsing multiple trees of markdown files with HTML rendering, syntax highlighting and search

README 文档

README

This is an extension of TreeMDown to handle and display multiple trees of markdown files.

Installation

Via composer

Checkout the current release at packagist.org.

Add to your composer.json:

{
	"require": {
		"hollodotme/treemdown-multi": "~1.0"
	}
}

Basic usage

<?php

// Require composer autoloading
require_once 'vendor/autoload.php';

use hollodotme\TreeMDown\TreeMDown;
use hollodotme\TreeMDownMulti\TreeMDownMulti;

$multi_view = new TreeMDownMulti();

$multi_view->addTree( new TreeMDown(__DIR__ . '/my_docs'), 'My documents');
$multi_view->addTree( new TreeMDown(__DIR__ . '/your_docs'), 'Your documents');

$multi_view->display();

Advanced Usage

You can configure each of the TreeMDown instances to fit your needs. Please visit the documentation of TreeMDown to see all available options.

Here is a simplyfied example:

<?php

// include composer autoloading
require_once 'vendor/autoload.php';

// IMPORTANT: Don't use hollodotme\**TreeMDown**\TreeMDown here!
// This package has an extended TreeMDown class

use hollodotme\TreeMDownMulti\TreeMDown;
use hollodotme\TreeMDownMulti\TreeMDownMulti;

// Create instance
$multi_view = new TreeMDownMulti();

// Configure your markdown primary dir
$tree1 = new TreeMDown( '/path/to/your/markdown/files' );
$tree1->hideEmptyFolders();
$tree1->setProjectName( 'Your markdown files' );
$tree1->enablePrettyNames();
$tree1->hideFilenameSuffix();

// Configure other dir
// Note: No output options set to show the difference
$tree2 = new TreeMDown( '/path/to/other/markdown/files' );
$tree2->setProjectName( 'Other markdown files' );

// Make "Yours" default (3rd parameter)
$multi_view->addTreeMDown( $tree1, 'Yours', true );
$multi_view->addTreeMDown( $tree2, 'Others' );

// Display
$multi_view->display();

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2014-08-29

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固