Make a VS Code extension that displays content from Learn X in Y Minutes.
I imagine this'd work as follows:
- Open the Command Palette
- Run the command 'Show example from Learn X in Y Minutes'
- Pick a page from the list of options (Essentially just the page names, Ruby, Go, PHP, Python, etc.)
- The extension opens a view that displays the formatted Markdown. (Use VS Code's built-in Markdown renderer to render the Markdown.)
The extension would only support English to start with, I guess. I'm not sure if it'd be sufficient to download the markdown file from the Learn X in Y Minutes repo on-demand or if it'd be better to bundle it in the extension. The license for LXIYM is CC-BY-SA so credit needs be given, obviously.
It could also just open in a separate browser window.
- For rendering the Markdown document: https://code.visualstudio.com/api/extension-guides/webview
- For creating the command to open the markdown document: https://code.visualstudio.com/api/extension-guides/command
showQuickPick
can be used to pick to select the programming language for which to show documentation. It includes an input field by default. See also this example extension.- Your First Extension guide
MarkdownString
might be useful for rendering the Markdown document, but I'm not sure if it can be used for a separate view?- Compiling Markdown into HTML, will be useful for parsing LXIYM's Markdown.
Can probably create a simple script to pull in the LXIYM git repo, pull out all the Markdown files, and then turn them into the HTML that can be packaged with the extension (the official markdown preview extension uses markdown-it I think?). The command would trigger the creation of a Webview which would display one of the HTML documents that's included with the extension.
Can probably also take the Markdown styling from the Markdown Preview extension?