yiisoft / yiisoft/yii2-debug

Application Context (routes, views, config)

Open
#552 0 comments 2 reactions 1 assignee View on GitHub

@WarLikeLaux is already working on this.

Since Mar 6, 2026.

status:ready for adoption
Dominant language
PHP
Stars
202
Forks
147
Avg merge
1h 54m
Merged PRs (30d)
1

Description

Proposed new feature or change

Add a debug panel that shows the full request context in a structured, copyable format:

  • Matched route, controller/action, parameters
  • Rendered views and layout (in order)
  • Applied filters/behaviors

With a "Copy as text" button for quick export:

Route: site/index
Controller: app\controllers\SiteController::actionIndex()
Layout: @app/views/layouts/main.php
Views:
  - @app/views/site/index.php
  - @app/views/site/_sidebar.php (partial)
Filters: AccessControl, VerbFilter

Laravel Telescope has a similar request watcher that shows route, middleware and controller info per request. Symfony Profiler also has a Router panel. Yii2 debug toolbar currently has no equivalent.

Useful for debugging unfamiliar projects and for providing context to AI coding assistants.

All data is already available via Yii::$app->requestedRoute, View events and controller metadata. Follows the existing panel architecture, no BC impact.

Would this be accepted as a PR?

Happy to implement this if there is interest.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.