React Hot Toast

炙手可热的 React 通知。轻量级的、可定制的、默认的、漂亮的。「Smoking hot React Notifications 🔥 Lightweight, customizable and beautiful by default.」

Github stars Tracking Chart

Features

  • 🔥 Hot by default
  • 🔩 Easily Customizable
  • Promise API - Automatic loader from a promise
  • 🕊 Lightweight - less than 5kb including styles
  • Accessible
  • 🤯 Headless Hooks - Create your own with useToaster()

Installation

With yarn

yarn add react-hot-toast

With NPM

npm install react-hot-toast

Getting Started

Add the Toaster to your app first. It will take care of rendering all notifications emitted. Now you can trigger toast() from anywhere!

import toast, { Toaster } from 'react-hot-toast';

const notify = () => toast('Here is your toast.');

const App = () => {
  return (
    <div>
      <button onClick={notify}>Make me a toast</button>
      <Toaster />
    </div>
  );
};

Documentation

Find the full API reference on official documentation.

Main metrics

Overview
Name With Ownertimolins/react-hot-toast
Primary LanguageTypeScript
Program languageTypeScript (Language Count: 4)
Platform
License:MIT License
所有者活动
Created At2020-12-07 22:05:40
Pushed At2025-02-15 11:43:52
Last Commit At
Release Count23
Last Release Namev2.5.2 (Posted on 2025-02-15 12:17:49)
First Release Namev0.1.2 (Posted on 2020-12-08 23:50:27)
用户参与
Stargazers Count10.3k
Watchers Count25
Fork Count345
Commits Count340
Has Issues Enabled
Issues Count258
Issue Open Count108
Pull Requests Count48
Pull Requests Open Count18
Pull Requests Close Count30
项目设置
Has Wiki Enabled
Is Archived
Is Fork
Is Locked
Is Mirror
Is Private