Multiple matches on same string
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 42/100
- Issue 類型
- 缺陷
- 描述清晰度
- 基本清楚
- 活躍度
- 停滯
- 技術堆疊
- javascript, react
- 領域
- frontend
研究方向
在同一個字串上重現兩次替換,並檢查與使用 flatten 相關的替換邏輯;將其行為與 flattenDeep 進行比較。完成的標準是:重複匹配能保留返回的 React 元件,並且在相關文件中明確說明 callback 需要返回一個陣列。
由索引模型根據 Issue 內容生成。
描述
Hi there, when using this twice on the same string what is happens is as follows, the first string matches and an array containing the react component returned from the callback fucktion is returned, and than in the second replace, it skips the symbol that was returned from the first run because it is not a string...
I think the solution would be to use flattenDeep instead of flatten, and clarify that callback functions should return an array instead of a component.
- 主要語言
- JavaScript
- 星號
- 666
- 分支
- 54
- PR 合併指標
- 30 天內沒有已合併 PR
環境準備
我們還沒有檢查這個專案的環境設定檔。先看它的 README,通用步驟見我們的新手貢獻指南。
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
iansinnott/react-string-replace 的其他 Issue
-
難度 4/5 3-5 天 新手友好度 35/100
-
難度 3/5 1-2 天 新手友好度 35/100
-
難度 3/5 1-2 天 新手友好度 35/100
iansinnott/react-string-replace#89 · 1 個 reaction ·
-
難度 2/5 1-3 小時 新手友好度 38/100
-
難度 3/5 1-2 天 新手友好度 30/100
iansinnott/react-string-replace#64 · 2 則留言 · 2 個 reaction ·
查看 iansinnott/react-string-replace 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 90/100
維護者通常 1 天內回覆
-
Design only Leadership Survey SLFS
難度 2/5 1-3 小時 新手友好度 70/100
bcgov/digital-journeys#2293 ·
-
難度 2/5 1-3 小時 新手友好度 72/100
tursodatabase/turso#9405 ·
維護者通常 1 天內回覆
-
Toolkit
難度 2/5 1-3 小時 新手友好度 88/100
維護者通常 1 天內回覆
-
API Bug
難度 2/5 1-3 小時 新手友好度 78/100
ProjectSidewalk/SidewalkWebpage#5556 ·
維護者通常 1 天內回覆