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

Remove inline requestSubmit handlers that double-submit collection filter forms

オープン 初心者向け
#2,824 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

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

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
68/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
javascript, rails, ruby
領域
frontend, testing

調査の方向性

一覧にあるフィルター partial から始め、各インラインハンドラーが Stimulus コントローラー collection を使うフォーム内にあることを確認してください。Issue では、他の一部のビューがそれらのハンドラーに依存していると警告されています。#2815 がマージされるのを待ち、その request spec と system spec のパターンに従ってください。ハンドラーが存在しないことと、各フィルターが引き続き結果を更新することを確認します。フレームのないフォームにデバウンス付きのテキスト送信を追加する場合は、#2823 のフォーカス修正も考慮してください。

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

説明

blocked

🤖 From Claude:

Many filter forms submit twice on each change, sending two requests where one would do.

Why it happens

  • These forms have the collection Stimulus controller, which already submits on select/date/checkbox changes and debounces text input.
  • Their fields also carry inline onchange/oninput="this.form.requestSubmit()", so each change fires a second request.
  • Inline text oninput also skips the debounce: it submits on every keystroke.

Likely affected (inline handler + collection in the same file)

  • app/views/quotes/_search_boxes.html.erb
  • app/views/topic_subscriptions/_search_boxes.html.erb
  • app/views/staff_taggings/_search_boxes.html.erb
  • app/views/features/_search_boxes.html.erb
  • app/views/stories/_search_boxes.html.erb
  • app/views/community_news/_search_boxes.html.erb
  • app/views/monthly_reports/_search_boxes.html.erb
  • app/views/comments_and_communications/_comments_and_communications_filters.html.erb
  • app/views/author_credit_divergences/_filters.html.erb
  • app/views/categories/_search_boxes.html.erb
  • app/views/notifications/_search_boxes.html.erb

Check first

  • Other views have inline requestSubmit without collection in the same file, e.g. sectors/_search_boxes, events/_funder_filter, events/_event_search_filter.
  • Only remove the handler where the field actually sits inside a collection form; otherwise it's the only thing submitting.

Fix (done for the comments filters and workshop logs in #2815)

  • Delete the inline handler; leave submitting to collection.
  • Request spec: the filter form has no onchange=/oninput=.
  • System spec: each filter still refreshes the results.
  • For frameless forms that gain debounced text submits, pair with the focus fix in #2823.

Blocked on

  • #2815 merging (reference fix and specs).
主要言語
Ruby
スター
15
フォーク
28
平均マージ
1日 12分
マージ済み PR(30日)
262

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

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

rubyforgood/awbw のほかの issue

rubyforgood/awbw の issue をすべて見る

似ている issue

Ruby の issue をもっと見る

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

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