You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

yesno-dialog

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

yesno-dialog

Javascript yes no dialog

0.2.1
latest
Source
npmnpm
Version published
Weekly downloads
3.2K
-7.54%
Maintainers
1
Weekly downloads
 
Created
Source

Javascript yes no dialog

Build status License

Tiny customizable vanilla js confirm dialog

Install

npm install --save yesno-dialog

Usage

import yesno from "yesno-dialog";

showCatButton.addEventListener('click', async () => {
  const yes = await yesno()
  if (yes) // show the cat
})

Js yes no dialog example

Customization

import yesno from "yesno-dialog";

showCatButton.addEventListener('click', async () => {
  const yes = await yesno({
    labelYes: "Yep",
    labelNo: "Nope",
    bodyText: "Sure?"
  })
  if (yes) // show the cat
})
.jsyesnodialog {
  --color: #e91e63;
}

Js yes no dialog customize

Codesandbox examples

  • Initial
  • Change theme
  • Customize text

License

MIT © SidKH

Keywords

js

FAQs

Package last updated on 07 Aug 2020

Did you know?

Socket

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

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.