Filter documentation via a query parameter for better browser interoperability

未关闭
#2,026 5 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 2 天内回复

@torresga 已经在做这个了。

开始于 2023年10月5日。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
38/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
停滞
技术栈
ruby
领域
search, web-dev

调研方向

从 issue 中显示的 DevDocs 查询端点 https://devdocs.io/#q=%s 开始,跟踪浏览器如何处理 q 参数和文档过滤。完成的标准是 URL 可以包含 doc=ruby3-1,使搜索仅针对请求的文档集执行。

由索引模型根据 Issue 内容生成。

描述

feature

Feature request

Filter documentation via an optional query parameter

Summary

DevDocs makes it really easy to filter on a specific set of docs in the UI, which is great. I use this in conjunction with browser site search to pass queries directly to the DevDocs search endpoint to skip landing on the main page first. However, there is one disadvantage: I can't seem to filter the documentation from the search endpoint directly. If want to search for a ruby-specific method from site search, I need to land on the main DevDocs page and filter manually.

Browsers are embracing custom site search functionality to allow quick access to search endpoints that can be invoked via a shortcut and this has become an important part of my workflow. It would be great to have documentation filtering in the search API to improve the interoperability of DevDocs search.

Examples

The query endpoint looks like this:

https://devdocs.io/#q=%s where %s is replaced with my query string

It would be great to be able to do something like this to search only within Ruby 3.1:
https://devdocs.io/#q=%s&doc=ruby3-1

主要语言
Ruby
星标
39.7k
派生
2.7k
平均合并
5 天 10 小时
30 天内合并 PR
13

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

freeCodeCamp/devdocs 的其他 Issue

查看 freeCodeCamp/devdocs 的全部 Issue

相似的 Issue

更多 Ruby Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。