定制 patrick-maynard/audit-class-generator 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

patrick-maynard/audit-class-generator

最新稳定版本:v0.7.0

Composer 安装命令:

composer require patrick-maynard/audit-class-generator

包简介

A simple tool that allows developers to see which Twig templates are being used to generate a page

README 文档

README

This simple package adds pseudorandomized audit tags to your Twig html class definitions.

This can be useful if you don't have traditional debugging tools available.

By seeing a short, pseudorandom audit tag among the classes applied to an html element, you can quickly determine exactly which Twig template the html element came from.

That can save significant debugging time, since you don't have to guess at which Twig template to modify for a given task.

In other words, if you can view the source in a browser, you can now grep definitively for any HTML tag that already has a "class" attribute, finding exactly which Twig template generated that DOM element. Pretty neat!

Installation

To install this tool as a dev dependency:

composer require --dev patrick-maynard/audit-class-generator

Installing this in a production environment is not recommended.

Usage

Once the tool has been installed, you can run it directly from Composer’s vendor/bin

vendor/bin/audit-class-generator

This will open a new git branch and apply temporary audit classes to any Twig HTML elements that already have a "class" attribute defined.

Then view the source of the page you want to debug in a browser. You'll see that any tag that already had a "class" attribute now has a unique, pseudorandom class like audit_34f39d appended to the class list.

Just grep for that audit class, and you'll find the Twig template you want in a jiffy.

Happy debugging!

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-02-01

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固