PHPackages                             sungmee/editormd - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. sungmee/editormd

ActiveLibrary

sungmee/editormd
================

Editor.md with Qiniu Storage for Laravel

113PHP

Since May 30Pushed 7y ago1 watchersCompare

[ Source](https://github.com/sungmee/editormd)[ Packagist](https://packagist.org/packages/sungmee/editormd)[ RSS](/packages/sungmee-editormd/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependenciesVersions (1)Used By (0)

Editor.md with Qiniu upload for Laravel.
========================================

[](#editormd-with-qiniu-upload-for-laravel)

**Laravel** 的 Markdown 编辑器 **Editor.md**，配置图片服务器上传（可自定义储存系统，如 S3 等）以及**七牛云**上传。服务器上传使用了 **Laravel** 的文件系统；而七牛上传则依赖七牛官方的 SDK，直接上传到您配置的 **七牛云 Bucket** 下，无需通过服务器中转，速度快，并节省带宽资源。

注意，如果上传到服务器出现**500**错误，一般是运行环境没有安装 PHP 的 FILEINFO 扩展所致，请自行 Google 解决。

安装与配置
-----

[](#安装与配置)

```
"require": {
    ...
    "sungmee/editormd": "dev-master"
},
```

如上所示，在 **Laravel** 项目根目录的 `composer.json` 的 `require` 中新增 `"sungmee/editormd": "dev-master",` 依赖，然后执行 `composer update` 进行安装。

安装好依赖后，在 `config/app.php` 中添加：

```
'providers' => [
    Sungmee\Editormd\EditormdServiceProvider::class,
],
```

然后在 **SSH** 中 cd 到 **Laravel** 项目根目录，执行下面 `Artisan` 命令，发布本扩展包的配置和路由：

```
php artisan vendor:publish

```

如需强制发布，可以在上面命令后加上 `--force` 参数，注意这将会覆盖一些旧的配置文件。

### 使用本地文件储存系统

[](#使用本地文件储存系统)

Editor.md 编辑器图片默认使用 **Local** 储存系统并会上传到 **Laravel** 项目的 `storage/app/public` 目录下。

为了能公开访问，你需要创建 `public/storage` 文件夹，然后作为符号链接到 `storage/app/public` 文件夹。可以使用以下 `Artisan` 命令创建符号链接：

```
php artisan storage:link

```

### 使用七牛云文件储存系统

[](#使用七牛云文件储存系统)

根据实际情况，修改 **Laravel** 项目根目录下的 `config/editormd.php` 配置文件下面列出的几个七牛相关项：

```
'qiniuAccessKey' => '',  // 七牛 AccessKey
'qiniuSecretKey' => '',  // 七牛 SecretKey
'qiniuBucket'    => '',  // 七牛 Bucket 名字
'qiniuPublishUrl'=> '',  // 七牛 CDN 加速域名
'qiniuUploadUrl' => '',  // 七牛储存上传 URL
```

至此，所有配置完毕。

使用说明
----

[](#使用说明)

在需要使用 **Editor.md** Markdown 编辑器的 `blade` 模板里面使用下面三个方法：`editor_css()` 、`editor_js()` 和 `editor_config()` 即可调用 **Editor.md** 编辑器。

- `editor_css()`：编辑器 CSS 样式表文件（必须）。
- `editor_js()`：编辑器 Javascript 文件（必须）。
- `editor_config()`：编辑器配置的 JS 代码，如果你不使用本扩展包的方法，可以根据 Editor.md 说明自行配置。

**注意：本扩展包编辑器 TEXTAREA 的父级容器默认使用 `editormd` ID。**

其它详细配置，请看 `config/editormd.php` 文件的注释。

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/17464917?v=4)[摩凝(M.Chan)](/maintainers/sungmee)[@sungmee](https://github.com/sungmee)

---

Top Contributors

[![sungmee](https://avatars.githubusercontent.com/u/17464917?v=4)](https://github.com/sungmee "sungmee (19 commits)")

### Embed Badge

![Health badge](/badges/sungmee-editormd/health.svg)

```
[![Health](https://phpackages.com/badges/sungmee-editormd/health.svg)](https://phpackages.com/packages/sungmee-editormd)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
