Skip to content
Projects

NitrogenZLab/ting has 368 GitHub stars and 30 forks. GitHot measured 0 stars in 24 hours. Last checked 2026-11-17 02:25 UTC. Last push 2024-11-10.

How these counts are measured

Measured star growth

in 24h
0
in 7 days
Update delayed
in 15 days
Update delayed
in 1 month
Update delayed

Net star changes over overlapping periods, not daily totals. Missing measurements are left blank. Stars measure attention, not software quality.

About

๐Ÿž Flexible and customizable React Native toast/alert notifications with support for positioning, custom rendering, click handlers, and duration control. Written in Swift and Kotlin

Creative & Media

README.md

Original

Logo1.2.3 BuyMeACoffee Kofi

Overview

Turbo Native Modules Swift Kotlin

Ting - React Native Toast | Product Hunt

๐Ÿž Flexible and customizable React toast notifications with support for positioning, custom rendering, click handlers, and duration control.

Video Demo ๐Ÿ“บ

ios android Modal

Installation

yarn add @baronha/ting
or
npm i @baronha/ting

If you want to use Expo. Burnt is the solution for you.

iOS

New Architecture

cd ios && RCT_NEW_ARCH_ENABLED=1 bundle exec pod install --verbose

Older

cd ios && pod install --verbose

Usage

Toast

import { toast } from '@baronha/ting';
// ...
const options = {
  title: 'Done ๐Ÿ˜Ž',
  message: 'Successful!!',
};

toast(options); // easy to use

Customize Icon

import { toast } from '@baronha/ting';
// ...
const options = {
  // ...
  title: 'Vietnamese Gangz ๐Ÿ˜Ž',
  message: 'Anh em tao lร  Vietnamese Gangz',
  titleColor: '#D60A2E',
  icon: {
    uri: require('./vietnam.png'), // or remote
    size: 24,
  },
};

toast(options); // icon is ๐Ÿ‡ป๐Ÿ‡ณ

Alert

import { alert } from '@baronha/ting';
// ...
const options = {
  title: 'Done ๐Ÿ˜Ž',
  message: 'Successful!!',
};

alert(options); // easy to use

Initialization

Instead of using too many options like this:

const options = {
  // ...
  messageColor: '#D60A2E',
  titleColor: '#D60A2E',
  icon: {
    uri: require('./vietnam.png'), // or remote
    size: 24,
  },
  shouldDismissByTap: true,
  position: 'bottom',
  // ... bla bla bla
};

toast(options);

You want to initialize the default options for all subsequent use of toast or alert. You can use the setup function that is called when the application is initialized. Do the following:

import { setup } from '@baronha/ting';

const initOption = {
  toast: {
    messageColor: '#D60A2E',
    titleColor: '#D60A2E',
    backgroundColor: '#ffffff',
    // ... more and more
  },
  alert: {
    // ... alert's option
  },
};

setup(initOption);

// Use it next time. You can completely override it on subsequent calls
toast({
  title: 'Ting!',
  message: 'Easy toast for React Native',
});

alert({
  title: "What's up bruhhh!",
  message: 'Easy Alert for React Native',
});

Options

Property Type Default value Platform Toast Alert Description
title string null Both โœ… โœ…
message string null Both โœ… โœ…
titleColor string null Both โœ… โœ… The color of the title text in hexadecimal format (e.g., #FF0000)
messageColor string null Both โœ… โœ… The color of the message text in hexadecimal format (e.g., #00FF00)
icon object null Both โœ… โœ… See Icon
preset string done Both โœ… โœ… done, error, none, spinner
duration number 3 Both โœ… โœ… The lifetime of the toast (seconds)
titleColor string null Both โœ… โœ…
shouldDismissByDrag boolean true Both โœ…
position string top Both โœ… Toast is displayed from top or bottom
haptic string null iOS โœ… success, warning, error, none
shouldDismissByTap boolean true Both โœ…
borderRadius number null Both โœ…
blurBackdrop number null Android โœ…
backdropOpacity number null Android โœ…
backgroundColor string #ffffff Both โœ… โœ… The background color of the toast in hexadecimal format (e.g., #0000FF)

Icon

icon Type Default value Platform
uri string null Both
size number null Both
tintColor string null Both

To Do

  • Initialize for the first time (v.1.0.5)
  • tintColor for icon (v.1.0.5)
  • backgroundColor (v.1.0.3)
  • spinner preset for toast (v.1.1.0)
  • custom color like StyleSheet (e.g. #fff, red, rgba(0, 0, 0, .8))
  • shouldDismissByDrag on Android
  • callback

Performance

We're trying to improve performance. If you have a better solution, please open a issue or pull request. Best regards!

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

Contributors โœจ

Thanks go to these wonderful people:

4cc3ssX
Ryam
baronha
Bแบฃo Hร .
Acetyld
Dion Grendelman
jeongshin
Huckleberry
tuanngocptn
Nick - Ngoc Pham

License

MIT AlertKit SPIndicator EasyWindow