Users of Unison Share can expect a faster experience when searching for Unison terms, thanks to a new search backend.
If you haven't tried out the search functionality on Unison Share before, you should be aware of a few conventions:
- You can currently only search for terms when inside a particular project. (You can't search all the projects on Unison Share for their copy of
jsonschema.lib.base.data.List.map
from the front page, sorry.) - The Unison Share search functionality is designed to find term definitions and their docs, not instances where a particular term is being called.
- To search for a term, click, "search" in the project's sidebar or enter "/" for a shortcut to the search bar.
Here are some helpful search tips from Unison teammate Chris Penner:
- Searches are scoped to the sidebar perspective
- All searches will be performed from whichever project-root your perspective is within.
- If you're not within any project roots, for example if you're search perspective is in your general
public
namespace, then it will search all projects reachable within your scratch namespace. - If your perspective is within a dependency, e.g.
.public.myproject.lib.base.data.List
then it will search within that dependency's project-root, in this case it will search in.public.myproject.lib.base
- Dependencies of your current project-root are not currently included in the search.
- Search syntax matters.
- Each search query is split into segments.
- Names match a list of segments if each segment appears in the name in order, case-insensitively. E.g. The segments
["list", "map"]
match the namebase.data.List.foldMap
, but not data.''Map.toList'' - Segments are split up by the following:
- CamelCase, e.g. foldMap is split into
["fold", "Map"]
, and fM is split into["f", "M"]
- Dots, e.g. List.Map ->
["List", ".", "Map"]
- Spaces, e.g. List Map ->
["List", "Map"]
- CamelCase, e.g. foldMap is split into
Go ahead and give it a try! 🌻