Socket
Socket
Sign inDemoInstall

mini-alert

Package Overview
Dependencies
0
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    mini-alert

Just a small javascript notification popup for ES6 and/or React.


Version published
Weekly downloads
9
decreased by-18.18%
Maintainers
1
Install size
11.8 kB
Created
Weekly downloads
 

Readme

Source

mini-alert

NPM version

Just a small javascript notification popup for ES6 and/or React.

miniAlert

Installation

$ npm install mini-alert

Examples


  import miniAlert from 'mini-alert';
  import 'mini-alert/miniAlert.css';
  // import 'mini-alert/miniAlert.scss'; // <!-- SCSS file (optional)

  miniAlert({
    text: "Simple text!!"
  });

  function handleAlert() {
  
    miniAlert({
      overflow: true,         // <-- disable behind the alert
      autoremove: true,       // <-- automatic remove
      time: 500,              // <-- milliseconds
      size: 'large',          // <-- small, medium, large
      cartoon: true,          // <-- "cartoon effect" true/false
      limit: 4,               // <-- max alerts visible at the same time
      text: "Hello world!!"
    });

  }

  function App() {

    return (
      <div>
        <button onClick={handleAlert}>Click me!!</button>
      </div>
    );

  }

Demo

Just a example project where you can see miniAlert in action..

License

Licensed under MIT

Keywords

FAQs

Last updated on 05 Jul 2020

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc