akiran / akiran/react-slick

Radio buttons doesn't work properly with react-slick

未關閉
#1,464 1 則留言 1 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
JavaScript
星號
11.9k
分支
2.1k
PR 合併指標
30 天內沒有已合併 PR

描述

Radio buttons don't work properly if they are inside a react-slick. You need to click twice a radio button to them changes the checked value and appear like a checked button, and if you have more than one radio button group some weird stuff will happen. Like, every checked button will uncheck, but the state will remain the same.

**Solution**: You have to use de property `infinite: false`, at the config props of the slider, and after that, they will work properly.

Test: https://codesandbox.io/s/kx1o05nmv5

Thanks!

貢獻指南

開啟貢獻指南

評估

這個 Issue 還沒有評估資料。

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。