Skip to content

Application Context (routes, views, config) #552

@WarLikeLaux

Description

@WarLikeLaux

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.

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions