CodeyBoi / CodeyBoi/appendix3

Extract all forms into their own component

オープン
#62 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る
enhancement
主要言語
TypeScript
スター
5
フォーク
1
平均マージ
15分
マージ済み PR(30日)
21

説明

Right now we have forms directly on the page, and we update the form fields by a call to `form.setValues`. This is problematic, as it makes `form.isDirty` not work correctly, as it only returns true if a field has been edited and is different from its `initialValue`.

The solution is to extract each form into a component. We can then in the parent component fetch the data and then pass the data as props, e.g. ``. We can then in the form component set the initialValues directly to the passed data.

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

まずページレベルのフォームとその form.setValues 呼び出しを見つけ、次に独自のコンポーネントにすべき各フォームを特定します。取得したデータをそれらのコンポーネントに渡し、props から initialValues を設定します。完了の条件は、抽出したすべてのフォームで編集内容が form.isDirty に正しく反映されることです。

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

評価

技術スタック
typescript
領域
frontend
issue の種類
リファクタリング
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
35/100

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

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