react-native-rn-toast

1.0.0 • Public • Published

react-native-rn-toast

A react native module to show toast like android, it works on iOS and Android(use ToastAndroid from react-native).

License MIT

Getting started

$ npm install react-native-rn-toast --save

Usage

import Toast from 'react-native-rn-toast';
 
Toast.show('toast test',Toast.SHORT);
Toast.showWithGravity('toast test',Toast.SHORT, Toast.CENTER);
Toast.showWithGravityAndOffset('toast test',Toast.CENTER, 20, 25);

Mehtod

show()

static show(message, duration)

showWithGravity()

static showWithGravity(message, duration, gravity)

showWithGravityAndOffset()

static showWithGravityAndOffset(message, duration, gravity, xOffset, yOffset)

Properties

SHORT

Toast.SHORT;

LONG

Toast.LONG;

TOP

Toast.TOP;

BOTTOM

Toast.BOTTOM;

CENTER

Toast.CENTER;

Package Sidebar

Install

npm i react-native-rn-toast

Weekly Downloads

0

Version

1.0.0

License

MIT

Unpacked Size

9.64 kB

Total Files

7

Last publish

Collaborators

  • happydemoney