npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

iu-toast

v1.1.2

Published

原生js的toast插件,不依赖任何库。

Readme

中文 | ENGLISH

iu-toast

The native js toast plug-in does not depend on any libraries.

Installation & Use

  • Introduction Method 1:
<link rel="stylesheet" href="iu-toast.min.css">
<script src="iu-toast.min.js"></script>
  • Introduction Method 2:
npm install iu-toast
import 'iu-toast/dist/iu-toast.min.css'
import iToast from 'iu-toast';
  • Use
iToast('提示内容')
// 成功提示
iToast.success()
// 失败提示
iToast.fail()
// 加载提示
iToast.loading()

API

| Method | Description | Parameter | Return value | | ---------------------- | ------------------------------------------------------------ | -------------------- | -------------- | | iToast | Display tips | options or message | toast instance | | iToast.loading | Show loading tips | options or message | toast instance | | iToast.success | Prompt for successful display | options or message | toast instance | | iToast.fail | Display failure prompt | options or message | toast instance | | iToast.clear | Clear prompt | - | void | | iToast.allowMultiToast | Allow multiple Toast at the same time | - | void | | iToast.setConfig | Modify the default configuration for all Toast. You can specify the default configuration for a specified item by specifying the type. | options or type | void | | iToast.resetConfig | Reset the default configuration, which takes effect for all Toast. You can reset the default configuration of a specified item by specifying the type. | type | void |

Options

| Parameter | Description | Type | Default value | | --------- | ------------------------------------------------------------ | -------- | ------------- | | Type | The type of the prompt. Valid values: loading success fail text | string | text | | Position | The location of the display. Valid values: top bottom | string | middle | | Message | Text content | string | '' | | overlay | Do you want to disable background clicks? | boolean | false | | overlay | Whether the mask layer is displayed | boolean | false | | Duration | The display duration (ms). When the value is 0, toast does not disappear. | Number | 2000 | | onOpened | Callback function after full display | Function | - | | onClose | Callback function when closed | Function | - |

PS: when using loading api , success api , fail api When type The configuration item is invalid, success api , fail api Force overlay For true