Monorepo for Tangled tangled.org

repo code search: add filter controls that prefill the query (like /search) #4719

Open tomplanche.com
Open opened by tomplanche.com

On /search, clicking a language, author or sort option writes the matching key:value token into the search input.

On /{owner}/{repo}/search, the only guidance is the help text ("Narrow it with lang:go, file:readme, or case:yes"). Users must type the syntax themselves.

Proposal: add the same controls to repo search:

  • a language list (from the repo's language breakdown) → lang:<name>
  • a case:yes toggle
  • optionally, file: suggestions from the file index

Each control edits the query string, so the URL (?q=) stays the single source of truth and the page still works without JS.

Related: #612 (same idea for issue/PR filters), #4171 , #4558 .

Sign up or Sign in to add to the discussion.