npm.io
0.1.7 • Published 2 years ago

@types/react-native-toast-native

Licence
MIT
Version
0.1.7
Deps
1
Size
5 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/react-native-toast-native

Summary

This package contains type definitions for react-native-toast-native (https://github.com/onemolegames/react-native-toast-native).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react-native-toast-native.

index.d.ts

import { Platform } from "react-native";

export interface Style {
    width?: number | undefined;
    height?: number | undefined;
    backgroundColor?: string | undefined;
    color?: string | undefined;
    borderWidth?: number | undefined;
    borderRadius?: number | undefined;

    // iOS-only
    borderColor?: string | undefined;

    // Android-only
    paddingLeft?: number | undefined;
    paddingRight?: number | undefined;
    paddingBottom?: number | undefined;
    paddingTop?: number | undefined;
    fontSize?: number | undefined;
    lines?: number | undefined;
    lineHeight?: number | undefined;
    xOffset?: number | undefined;
    yOffset?: number | undefined;
    letterSpacing?: number | undefined;
    fontWeight?: string | undefined;
}

interface ToastNative {
    // Toast duration constants
    SHORT: any;
    LONG: any;

    // Toast gravity constants
    TOP: any;
    BOTTOM: any;
    CENTER: any;

    show(message?: string): void;
    show(message: string, duration: any, position: any, styles: Style): void;
}

declare const ToastNative: ToastNative;
export default ToastNative;

Additional Details

  • Last updated: Thu, 21 Dec 2023 1951 GMT
  • Dependencies: react-native

Credits

These definitions were written by Michele Bombardi.