Editor setup
Nola ships a VS Code extension, nola.nola-vscode. Other editors talk to the same language server — see the end of this page.
Install
Section titled “Install”Install Nola from the Visual Studio Marketplace, or from a terminal:
code --install-extension nola.nola-vscodeProjects created with npm create nola (and retrofits with --ide vscode) carry a .vscode/extensions.json that recommends the extension, so VS Code offers to install it when the folder opens.
What you get
Section titled “What you get”- Syntax highlighting for
.tsi: theinferandaskkeywords, extractor templates,ask with <provider>routing. - Diagnostics — Nola parse errors and TypeScript errors, reported at the original
.tsipositions. - Hover, completion, go-to-definition inside
.tsifiles. Prompt templates included: typing${.inside an instruction (marker, extractor, call hint) completes the prompt-scope members, and TS errors inside a template point at the exact source range. - Plain TypeScript interop —
.tsfiles that import.tsimodules get full types, and go-to-definition from.tslands on the originalinfer function(a bundled tsserver plugin). - Debugging — the “Nola: Launch File” configuration runs a
.tsientry under the Nola loader; breakpoints bind in.tsisource, stepping into an infer function works, and debug hover evaluates contextual parameters.
Keep .tsi inside the tsconfig include
Section titled “Keep .tsi inside the tsconfig include”The language server and the tsserver plugin only see .tsi files that your tsconfig.json admits, and they can only do that through a directory-style include:
{ "include": ["src"]}["src/**/*.ts"] would drop every .tsi file out of the program — auto-import stops offering your infer functions and .ts consumers lose their types. The scaffold’s tsconfig already uses the directory form.
Debugging with F5
Section titled “Debugging with F5”This is the launch configuration the scaffold writes to .vscode/launch.json when you choose VS Code (the extension also offers it under Add Configuration… → Nola: Launch File):
{ "version": "0.2.0", "configurations": [ { "type": "node", "request": "launch", "name": "Nola: Launch main", "program": "${workspaceFolder}/src/main.ts", "runtimeArgs": ["--import", "nola-lang/register", "--enable-source-maps"], "console": "integratedTerminal", "cwd": "${workspaceFolder}", "resolveSourceMapLocations": ["${workspaceFolder}/**", "!**/node_modules/**"], "skipFiles": ["<node_internals>/**", "**/node_modules/**"] } ]}Three entries are load-bearing:
runtimeArgs—--import nola-lang/registerlowers.tsiin memory with inline source maps that point back at the on-disk files;--enable-source-mapsmakes stack traces report.tsipositions.resolveSourceMapLocations— VS Code’s default only admits source maps for.jsfiles; without this entry the inline map of a.tsimodule is ignored and breakpoints never bind.skipFiles— without it, stepping over anasksurfaces inside the Nola runtime instead of landing on your next line.
With it in place: set a breakpoint in a .tsi file, press F5, step into an infer function with F11 (you land on its first statement), and hover a contextual parameter to see its value. This is the development and debugging path — production builds use nola build and run without the loader.
Other editors
Section titled “Other editors”The extension is a thin shell around two packages you can wire into any editor with an LSP client: @nola-lang/language-server (diagnostics, hover, completion, definition inside .tsi) and @nola-lang/typescript-plugin (types for .ts files that import .tsi). See their READMEs on npm: language-server, typescript-plugin.
Next: Project anatomy