expo switch

뱀기·2022년 6월 10일
0

Nurihaus

목록 보기
5/13

기본으로 제공하는 switch로 toggle 버튼 만들기


return (
  <ToggleBtn
        value={state}
        style={{
          transform: [{ scaleX: 60 / 51 }, { scaleY: 34 / 31 }],
        }}
        onValueChange={setState}
        trackColor={{ false: "transparent", true: "#7E57F4" }}
        thumbColor={colors.primaryWhite}
        ios_backgroundColor="#e5e5e5"
/>
          )
          
const ToggleBtn = styled.Switch``;

          

0개의 댓글