Debug "macros" (dbg! in templates) #13
Labels
accepted
This will be worked on
type: feature
Brand new functionality, features, pages, workflows, endpoints, etc.
There currently isn't an easy way to inspect a component in the browser. Supporting a
dbg!
-like syntax that resolves into an HTML comment would provide a first avenue in this direction.Writing
dbg!{value}
if value is e.g."five"
should result in a comment like<!-- value = "five" -->
, using prettyDebug
formatting.Alternative options I considered are hooking into tooling for certain JavaScript frameworks, looking for browser tooling hooks or even writing my own inspector integration. However, for now all that would lead to considerable implementation effort compared to outputting plain comments.
The text was updated successfully, but these errors were encountered: