Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

epic-chip-react-native

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

epic-chip-react-native

An elegant react native chip module.

  • 1.0.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3
increased by200%
Maintainers
1
Weekly downloads
 
Created
Source

Epic React Native Chip

npm npm runs with expo

An elegant & fully customizable chip 🚀

Epic Chip React Native


Features

  • 🌟 Full customizable.
  • Smooth & faster animation.
  • IOS and, Android Supported.
  • Compatible with Expo.
  • Written in TypeScript.

Getting Started

For npm Type npm i epic-chip-react-native to install it on your project.

For yarn do yarn add epic-chip-react-native.

Important

Please install React Native Vector Icons npm i react-native-vector-icons @types/react-native-vector-icons.

Installation

Use npm or yarn to install the library

NPM: npm i epic-chip-react-native

Yarn: yarn add epic-chip-react-native

import { EpicChip } from 'epic-chip-react-native';

const App = () => {
  return <EpicChip labelOptions={{label: "Epic Chip"}} />;
}

export detault App;

Using Ref#

You can also toggle chip using ref hook.

import { EpicChip, EpicChipRef } from 'epic-chip-react-native';

const App = () => {

const EpicChipRef = useRef<EpicChipRef>(null);

  return (
    <>
        <EpicChip 
        ref={EpicChipRef} 
        labelOptions={{label: "Epic Chip"}} 
        onChange={e => console.log(e)} // print boolean;
        />
        
        </View style={{marginVertical: 30}}>
            <Button 
            onPress={()=> EpicChipRef.current?.toggleCheck()}>
            Toggle Chip
            </Button>
        </View> 
        
    </>
  );
}

export detault App;

Props

namedescriptionrequiredtypedefault
labelOptionsChip label options includes [label, Icon].NO[string or JSX Element]
optionsChip options, [chipStyles, labelStyles, backgroundColor, labelColor]NOchipStyles: StyleProp<ViewStyle>, labelStyles: StyleProp<TextStyle>, backgroundColor: {focusColor: #hexCode, inActiveColor: #hexCode}, labelColor: {focusColor: #hexCode, inActiveColor: #hexCode}
typeChip typeNOMini, Micro, Large
modeChip mode.NOOutlined, SolidOutlined
checkIconIf you want to hide the checkmark icon, just make it false.NObooleanfalse
radiusBorder Radius of the chip.NOnumber15
isCheckedyou can specify a default value.NOboolean
isDisabledFor disabling the chip`.NO'boolean'false
checkedIconChanging the default check icon`.NOReact.ReactNode
onChangeCallback on item changeNO(value: boolean) => void
refref hook toggleCheck() // void function NO

Author

  • Abdullah Khan
  • Saif Ali Khan

License

MIT

Liked the Component? 😇


Keywords

FAQs

Package last updated on 06 Mar 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc