VS Code support for Phel - a functional Lisp that compiles to PHP.
Why this extension
Writing Phel without editor support means colourless code, no completion for the 400+ symbols in phel.core, and dropping back to PHP-level debugging. This extension fixes all three.
Highlighting - full coverage of forms, macros, reader macros, tagged literals (#inst, #regex, #php, …) and reader conditionals (#?(...)).
Completion for every public symbol in phel.core (47 special forms, ~70 macros, 394 functions).
Snippets for everyday scaffolding - defn, let, cond, try, deftest, ->, …
Native debug adapter - set breakpoints in .phel files; the adapter translates between Phel and the compiled PHP via Xdebug.
Install
In VS Code, open the Extensions sidebar (Cmd+Shift+X / Ctrl+Shift+X), search for "Phel Lang", click Install. Or from the terminal:
code --install-extension Phel-Lang.phel-lang
Requires VS Code 1.75+. Other paths (.vsix from GitHub releases, build from source, symlink for live development): see docs/installation.md.
First steps
Open any .phel file - highlighting kicks in automatically.
Try completion - start typing re- or swap and accept a suggestion.
Expand a snippet - type defn Tab and tab through the placeholders.
Set a breakpoint in .phel, add a launch config (see docs/debugging.md), press F5.