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

[RFC]: add support for filtering the side menu by REPL alias #17

Open
3 tasks done
kgryte opened this issue Sep 3, 2021 · 2 comments
Open
3 tasks done

[RFC]: add support for filtering the side menu by REPL alias #17

kgryte opened this issue Sep 3, 2021 · 2 comments

Comments

@kgryte
Copy link
Member

kgryte commented Sep 3, 2021

Description

This RFC proposes adding support for filtering the side menu according to a package's REPL alias.

Currently, a user can filter according to the nested package tree in the main project. However, it would be nice if a user could also filter according to REPL alias.

For example, the query

base.sin

would resolve the package

@stdlib/math/base/special/sin

in the side menu.

Similarly, the query

base.(sin|cos)

would resolve the packages

@stdlib/math/base/special/cos
@stdlib/math/base/special/sin

in the side menu.

Related Issues

No.

Questions

No.

Other

No.

Checklist

  • I have read and understood the Code of Conduct.
  • Searched for existing issues and pull requests.
  • The issue name begins with RFC:.
@kgryte
Copy link
Member Author

kgryte commented Sep 4, 2021

This is a little tricky to do because the side menu filter currently supports regular expression filters which may include the use of a . to indicate any character, not a literal period.

Hence, could be hard to disambiguate whether a user wants to search based on a REPL alias or a regular expression using the special . character.

@kgryte
Copy link
Member Author

kgryte commented Sep 10, 2021

Limiting filtering by REPL alias to only when the REPL API docs mode is active does not fully address the ambiguity. While it would provide a strong indication that a user wants to filter by alias, we would not be able to readily distinguish between

base.si

and

base..in

where, in the former, we want to use the . as a delimiter and, in the latter, to represent any character.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant