How mustache/rack-bug-mustache_panel works
Rack::Bug::MustachePanel instruments Mustache rendering to collect per-view render times and accessed variables, then presents them in a Rack::Bug panel. The excerpts show the instrumentation, thread-local state, panel view, and configured template; they do not show how applications register or invoke the panel.
Main entry points: mustache_extension.rb Render Instrumentation · mustache_panel.rb Mustache Panel · view.mustache Panel Template
Components 7
Mustache Instrumentation
- Render Instrumentation
lib/rack/bug/panels/mustache_panel/mustache_extension.rb - Thread-local Metrics
lib/rack/bug/panels/mustache_panel.rb
Panel Output
- Mustache Panel
lib/rack/bug/panels/mustache_panel.rb - Panel View
lib/rack/bug/panels/mustache_panel.rb - Panel Template
lib/rack/bug/panels/mustache_panel/view.mustache
Other components
- Application
- Mustache Engine
Connections 6
- Application → Mustache Engine: renders views
- Render Instrumentation → Mustache Engine: wraps rendering
lib/rack/bug/panels/mustache_panel/mustache_extension.rb - Render Instrumentation → Thread-local Metrics: records metrics
lib/rack/bug/panels/mustache_panel/mustache_extension.rb - Mustache Panel → Thread-local Metrics: reads and resets
lib/rack/bug/panels/mustache_panel.rb - Mustache Panel → Panel View: renders
lib/rack/bug/panels/mustache_panel.rb - Panel View → Panel Template: uses template
lib/rack/bug/panels/mustache_panel.rb