Open NigelBreslaw opened 1 week ago
I'm not sure how to exactly area'ize this correctly. But I think this could be built in piece:
debug()
invocations.We don't have a component for a debugger yet, let alone an issue for it. This really depends on a debugger. Although debug statement are special and could record their position (that would be useful to show the file and line line number also in the debug output), and the preview could hijack the debug call to send it to the LSP as a range for an inlay hint.
We don't have a component for a debugger yet, let alone an issue for it. This really depends on a debugger. Although debug statement are special and could record their position (that would be useful to show the file and line line number also in the debug output), and the preview could hijack the debug call to send it to the LSP as a range for an inlay hint.
That's exactly Nigel's proposal ;)
Also if terminal output gained a link to the file and line number that would be great too. Is this standardised as it does this for react apps in the normal VSCODE terminal without a plugin?
Idea is that in a declarative language the latest value for the bindings are essentially invisible. Making them temp visible inside the editor would be so useful. Also just seeing the latest value is way more useful than a stream of zillions of values flying past in the terminal.
inspired by Console Ninja if you use slint
debug()
in your code the very latest log would be shown inline in vscode at the end of the line. I was going to try and make a very hacky version by placing a unique ID in the debug message. Parse it out the terminal window and then show the rest of the debug info. But just don't have the time right now.Maybe a non hack version would get the name of the file and the line number from the LSP?
V 2.0
Then the 'next level' version would be any line that shows a property e.g
rotation: atan( dial.y / dial.x)
you could click something. Maybe as simple as clicking in the margin with the line numbers and reuse the break point system vscode has to also cause an inline latest value to show. I think Console Ninja has something like this? That way you get the debug, but without modifying any of your code.