Alpha pre-release. Expect rough edges and breaking changes.
Keep the code you are reasoning about in view. Pin the functions, classes, methods and lines you are working with into a panel beside the editor, where they stay live and highlighted in your colour theme.
Using it
The Punaise panel opens in the secondary side bar on the right (in the activity bar on VS Code before 1.106).
Pin the symbol under the cursor with Alt+P (Cmd+Alt+P on macOS), or click it, or one of its enclosing symbols, in the strip at the top of the panel.
Pin lines: select them and press Alt+P, or choose Pin Selection from the editor's context menu. A selection within one line, such as a double-clicked name, still pins the symbol.
Read a pin's signature and documentation on its card; click the card to expand the full code.
Note why a pin matters with Add note on its card.
Reorder pins by dragging, or with Alt+Up / Alt+Down. Open the source with ↗, remove a pin with ×, or use Clear all.
Themes group pins for separate tasks: click the theme name at the top of the panel to switch, create, rename or delete them.
Cards update as you edit. A renamed symbol shows as "Not found" until it is back. Pinned lines follow your edits; when they move, a small ⤳ says where to, and when they change, the card offers to re-pin them.
Pins and themes are kept per workspace. Copy Pins as JSON, Export Pins to File… and Import Pins… share them.
Works with any language whose extension provides document symbols. Tested with TypeScript and with Python through Pylance.
Privacy
No network access and no telemetry. Your code never leaves your machine: pins store names, line offsets and hashes, never code.