Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explore functions within the editor #3

Open
aleclarson opened this issue Aug 23, 2024 · 0 comments
Open

Explore functions within the editor #3

aleclarson opened this issue Aug 23, 2024 · 0 comments
Labels
enhancement New feature or request radashi-vscode Related to radashi-vscode

Comments

@aleclarson
Copy link
Member

aleclarson commented Aug 23, 2024

Currently, there are 2 options of exploration provided by the extension.

  • Explore Core Functions: Opens a webpage with all the core functions in a list.
  • Search Functions: Uses our Algolia instance and a local search to fuzzy match core functions, proposed functions (via PR to radashi-org/radashi), and local functions.

Proposal

I propose adding an “Explore Functions” command that opens a tab in the editor (similar to what we do for the View Documentation subcommand of the Search Functions command) which contains a list of functions provided by the current Radashi workspace. The list is HTML-structured, with each function's name and description, grouped accordingly. You can click a function cell to view its documentation in a new tab. There's also a link to view source code.

Visuals

The UI will resemble our API reference page, but much of the styling will be inherited from VS Code and the current VS Code theme.

We already have HTML for a function's individual documentation page (see here). We can probably reuse a lot of that, including the Shiki integration.

All local

The initial goal here is to display only the functions that actually exist in your Radashi. We can achieve this completely offline (e.g. no Algolia search) by scanning the exports of your Radashi's generated mod.ts module with @babel/parser.

Future plans

Later on, we can add subviews to this Explore Functions view like Core Functions and Proposed Functions, alongside My Functions (the default subview), with buttons to switch between.

@aleclarson aleclarson added enhancement New feature or request radashi-vscode Related to radashi-vscode labels Aug 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request radashi-vscode Related to radashi-vscode
Projects
None yet
Development

No branches or pull requests

1 participant