rn-native-toast
react native toast
Installation
npm install react-native-rct-toast
Usage
import Toast from "react-native-rct-toast";
// ...
Toast.show(message: string,duration: number,position: number,style: styleType): void
Toast.hide();
export interface styleType {
backgroundColor?: string; //背景色 #ffffff
color?: string; //字体颜色 #333333
horizontalPadding?: number; //横向padding
verticalPadding?: number; //垂直方向padding
fontSize?: number; //文字大小
fontWeight?: string; //字体是否粗体 bold | false
radius?: number; //圆角
}
type RCTToastType = {
show(
message: string,
duration: number,
position: number,
style: styleType
): void;
hide(): void;
SHORT: number;
LONG: number;
TOP: number;
CENTER: number;
BOTTOM: number;
};
Contributing
See the contributing guide to learn how to contribute to the repository and the development workflow.
License
MIT