Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

[Enhancement] Jump to Documentation — open p5.js reference from editor via context menu

オープン
#4,098 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 3 日以内に返信

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
55/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
静か
技術スタック
javascript
領域
frontend, web-dev

調査の方向性

Issue で言及されているカスタムコンテキストメニューコンポーネントと CodeMirror エディター統合レイヤーから始めます。右クリックハンドラーがカーソル位置を取得する方法を追跡し、次に CodeMirror の getTokenAt(cursor) を使用してトークンを特定します。「Go to Documentation」項目が対応する p5.js リファレンス URL を新しいブラウザータブで開けば完了です。

索引モデルが issue の本文から書いたものです。

説明

Feature Request On Hold
Increasing Access

When a user writes or selects a p5.js function using the autocomplete hinter (e.g. loadFont()), there is currently no way to quickly look up what that function does without leaving the editor, opening a browser tab, and manually searching the p5.js reference. This is slow and disruptive, especially for developers building larger sketches who need to check parameters and return values frequently.

Feature request details

Add a "Go to Documentation" option to the editor's right-click context menu. When clicked, it opens the official p5.js reference page for the selected/hovered token directly in a new browser tab.
Implementation outline:

Detect the token — Use CodeMirror's getTokenAt(cursor) to read the word at the cursor position when the context menu is triggered.
Construct the URL — Build a reference URL dynamically:

https://p5js.org/reference/p5/{token}
For example, right-clicking loadFont opens:
https://p5js.org/reference/p5/loadFont

Open in a new tab — Call window.open(url, '_blank') from the context menu handler.

Files likely affected:

Custom context menu component (wherever right-click menu is defined)
CodeMirror editor integration layer

User Experience

This mirrors the "Go to Definition" / F12 behaviour familiar from VS Code and other modern IDEs. The interaction would be:

User types or selects a p5.js function using autocomplete
User right-clicks the function name
Context menu shows "↗ Go to Documentation" as the first/highlighted item
Clicking it opens https://p5js.org/reference/p5/{functionName} in a new tab

Why this matters

Reduces context switching for beginners and experienced users alike
Consistent with IDE conventions users already know
Especially valuable during autocomplete-driven coding, where the user may not remember exact parameter order or return types
Low implementation complexity relative to the workflow improvement

Related / Prior Art

VS Code: hover + F12 / Ctrl+Click → Go to Definition
Chrome DevTools: documented function links in Console autocomplete

主要言語
JavaScript
スター
1.7k
フォーク
1.7k
平均マージ
3日 18時間
マージ済み PR(30日)
7

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

processing/p5.js-web-editor のほかの issue

processing/p5.js-web-editor の issue をすべて見る

似ている issue

JavaScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。