PHPackages                             shiroi/think-log-viewer - 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. [Logging &amp; Monitoring](/categories/logging)
4. /
5. shiroi/think-log-viewer

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

shiroi/think-log-viewer
=======================

thinkphp6 log视图工具

1.3.4(2y ago)3343[1 issues](https://github.com/hcr707305003/think-log-viewer/issues)MITPHPPHP &gt;=7.4

Since Jun 24Pushed 2y ago1 watchersCompare

[ Source](https://github.com/hcr707305003/think-log-viewer)[ Packagist](https://packagist.org/packages/shiroi/think-log-viewer)[ RSS](/packages/shiroi-think-log-viewer/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (2)Versions (37)Used By (0)

think-log-viewer
================

[](#think-log-viewer)

thinkphp6 log日志的视图扩展包

### 页面展示

[](#页面展示)

[![image](https://camo.githubusercontent.com/cb44c3ab555a68740a11be16c4f38cb5969a0690783ca5859af0e83a87dbb1e8/68747470733a2f2f73332e626d702e6f76682f696d67732f323032322f30362f32362f333338356231313036646264313738662e706e67)](https://camo.githubusercontent.com/cb44c3ab555a68740a11be16c4f38cb5969a0690783ca5859af0e83a87dbb1e8/68747470733a2f2f73332e626d702e6f76682f696d67732f323032322f30362f32362f333338356231313036646264313738662e706e67)

### 1.配置路由

[](#1配置路由)

```
// config\log.php 文件
return [
    // 默认日志记录通道
    'default'      => env('log.channel', 'file'),
    // 日志记录级别
    'level'        => ['error','notice','info','debug'],
    // 日志类型记录的通道 ['error'=>'email',...]
    'type_channel' => [],
    // 关闭全局日志写入
    'close'        => false,
    // 全局日志处理 支持闭包
    'processor'    => null,

    // 日志通道列表
    'channels'     => [
        'file' => [
            // 日志记录方式
            'type'           => 'File',
            // 日志保存目录
            'path'           => 'log',
            // 单文件日志写入
            'single'         => false,
            // 独立日志级别
            'apart_level'    => [],
            // 最大日志文件数量
            'max_files'      => 0,
            // 使用JSON格式记录
            'json'           => false,
            // 日志处理
            'processor'      => null,
            // 关闭通道日志写入
            'close'          => false,
            // 日志输出格式化
            'format'         => '[%s][%s] %s',
            // 日志输出的时间格式
            'time_format'    =>  'Y-m-d H:i:s',
            // 是否实时写入
            'realtime_write' => false,
        ],
        // 其它日志通道配置
    ],

];

// route\app.php 文件
Route::get('log_view', "\Shiroi\ThinkLogViewer\LogServer@index");

// .env 文件(设置该页面必须密码才能查看)
[LOG_VIEW]
IS_LOCK=true
LOCK_PASSWORD=123456
lock_hint_content=请输入验证码

```

### 2.运行thinkphp服务

[](#2运行thinkphp服务)

```
php think run

```

### 3.访问浏览器 `http://127.0.0.1:8000/log_view`即可

[](#3访问浏览器-http1270018000log_view即可)

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance13

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity59

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.

###  Release Activity

Cadence

Every ~12 days

Recently: every ~0 days

Total

36

Last Release

981d ago

Major Versions

0.0.2 → 1.0.02022-06-25

### Community

Maintainers

![](https://www.gravatar.com/avatar/d4d4a4362741a6d72cb10e38f5b9b5267b73cb9fa644fc5b7cc194be0c47efc6?d=identicon)[hcr707305003](/maintainers/hcr707305003)

---

Top Contributors

[![hcr707305003](https://avatars.githubusercontent.com/u/22547038?v=4)](https://github.com/hcr707305003 "hcr707305003 (38 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/shiroi-think-log-viewer/health.svg)

```
[![Health](https://phpackages.com/badges/shiroi-think-log-viewer/health.svg)](https://phpackages.com/packages/shiroi-think-log-viewer)
```

###  Alternatives

[psr/log

Common interface for logging libraries

10.4k1.2B9.1k](/packages/psr-log)[itsgoingd/clockwork

php dev tools in your browser

5.9k27.6M94](/packages/itsgoingd-clockwork)[graylog2/gelf-php

A php implementation to send log-messages to a GELF compatible backend like Graylog2.

41838.2M137](/packages/graylog2-gelf-php)[bugsnag/bugsnag-psr-logger

Official Bugsnag PHP PSR Logger.

32132.5M2](/packages/bugsnag-bugsnag-psr-logger)[consolidation/log

Improved Psr-3 / Psr\\Log logger based on Symfony Console components.

15462.2M7](/packages/consolidation-log)[datadog/php-datadogstatsd

An extremely simple PHP datadogstatsd client

19124.6M15](/packages/datadog-php-datadogstatsd)

PHPackages © 2026

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