Open nstrayer opened 8 months ago
One feature that came up today is the ability for YAML autocompletion and validation to work within the Notebook editor. RStudio and Quarto's VS code extension do stuff like this:
The validation uses precisely the same schema as the command line, and it also drives auto-completion when appropriate, again from the same sources:
The Positron notebook editor can, at least in principle, detect Quarto metadata blocks, and it would be nice for it to provide the same affordances.
This code is sort of factored out already in a way that is accessible to RStudio and VS Code both. It's not pretty, but the way this works is that quarto-cli
bundles (among other things) a Javascript file that has an API for querying completions and validations. Since the VS code extension and RStudio both know where quarto
is, they can access this file, and they know how to call it.
The files are all in ./src/resources/editor/tools/yaml/
inside a bundle, as well as https://github.com/quarto-dev/quarto-cli/tree/main/src/resources/editor/tools/yaml. The entry points themselves are:
This is all messy (insert banana guy meme here), but a pairing session should be enough for y'all to get your bearings.
Another thing that the VS code editor does is auto-completion for some Markdown constructs directly:
This would also be nice to have support for in the Notebook editor. These completions are defined in
And they are used by the VS Code extension in
What?
A new editor for notebook applications. The "basic" setup will be the minimum needed for a functional notebook experience. This won't necessarily result in a better notebook experience than the built-in vscode notebooks, but will be the foundation for building off of to create a better experience.
Steps
.ipynb
files using React2353
2350
2355
2357
2354
2351