siteone/craft-tracy
最新稳定版本:v1.4.0
Composer 安装命令:
composer require siteone/craft-tracy
包简介
Tracy plugin for Craft CMS 4
README 文档
README
Plugin integrates awesome nette/tracy debugging tool into Craft CMS. See Tracy in action here.
Requirements
- PHP 8.0.2+
- Craft CMS 4.0+
Installation
To install the plugin, follow these instructions.
-
Open your terminal and go to your Craft project:
cd /path/to/project -
Then tell Composer to load the plugin:
composer require siteone/craft-tracy -
In the Control Panel, go to Settings → Plugins and click the “Install” button for Tracy.
Usage
In addition to the standard dump($var), dumpe($var), bdump($var) functions in PHP, the plugin provides the following functions in templates:
{{ dump(entity) }} or {{ d(entity) }} - Dump variable in place.
{{ dumpe(entity) }} or {{ dd(entity) }} - Dump variable in place and exit.
{{ bdump(entity) }} or {{ bd(entity) }} - Dump variable to debug bar.
Settings
Some settings can be changed. Just create a config/tracy.php file, insert the following code (defaults) and change the values as needed:
<?php return [ // Maximum string length 'maxLength' => 150, // How deep will list 'maxDepth' => 4, // Hide values of these keys 'keysToHide' => [], // Visual theme (light, dark) 'dumpTheme' => 'light', // Display the location where dump() was called? 'showLocation' => false, ];
Official resources
Official Tracy resources can be found here:
统计信息
- 总下载量: 96
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-01-04
