react-native-switch-ios
TypeScript icon, indicating that this package has built-in type declarations

1.0.1 • Public • Published

react-native-switch-ios

React native iOS switch component that can be used in android and iOS projects with active and inactive color customization and cool iOS toggle animation .

Preview

Installation

$ npm install --save react-native-switch-ios

or

yarn add react-native-switch-ios

or

pnpm add react-native-switch-ios

Usage

import { useState } from "react";
import { Switch } from "react-native-switch-ios";

export const App = () => {
  const [toggle, setToggle] = useState(false);
  return (
      <Switch
         inactiveBgColor="#7d7d7d"
         activeBgColor"#34c759"
         isOn={toggle}
         onToggle={() => setToggle((prev) => !prev)} 
      />
  )
};

/react-native-switch-ios/

    Package Sidebar

    Install

    npm i react-native-switch-ios

    Weekly Downloads

    34

    Version

    1.0.1

    License

    MIT

    Unpacked Size

    6.31 kB

    Total Files

    6

    Last publish

    Collaborators

    • mehdifaraji