# t4t5/sweetalert

A beautiful replacement for JavaScript's "alert"

Repository: https://github.com/t4t5/sweetalert
Canonical: https://ross.abutalabs.com/products/sweetalert
Homepage: https://sweetalert.js.org
Language: TypeScript
License: MIT
License Family: permissive
Topics: modal, sweetalert, javascript, popup, dialog, alert, ui
Last push: 2023-04-15T22:54:03+00:00

## Health v2 (maintenance only)
Score: 23/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 0, release rhythm 8, longevity 100
- inputs: {"age_days": 4355, "days_push": 1236, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 22259, forks 2746 (observed 2026-08-28T04:11:32.509864+00:00)

## What it is
SweetAlert is a JavaScript library that replaces the native browser alert() with beautiful, customizable modal dialogs. It supports icons, confirm/cancel buttons, and promise-based or async/await interaction flows.

## Use cases
- show pretty confirmation dialogs instead of native alert
- display success, error, warning, and info popups
- ask users to confirm destructive actions with a promise-based modal
- customize modal text, icons, buttons, and theming
- use await to get user confirmation in async code

## When to choose
- you want an attractive drop-in replacement for JavaScript's alert()
- you need simple, promise-based confirm dialogs with minimal setup
- you want a lightweight, dependency-free modal library

## When to avoid
- you need complex multi-step forms or advanced modals (consider SweetAlert2 or a full modal framework)
- you need a library under active development with frequent updates
- you require accessibility features beyond basic dialogs

## Facets
- artifact type: library
- maturity: maintenance
- function: ui-components, frontend-framework
- domain: web-development, frontend
- platform: browser
- tags: alert-dialogs, modals, popups, javascript, typescript, promise-based, nodejs

## Member repositories
- t4t5/sweetalert (main) score 23

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:11:32.509864+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T16:57:22.656247+00:00, confidence not recorded.
  - readme: https://github.com/t4t5/sweetalert (fetched 2026-08-28T04:11:32.509864+00:00, sha c870df9ac19b)
  - homepage: https://sweetalert.js.org (fetched 2026-08-29T07:56:03.686603+00:00, sha 55a72c09c82b)
  - site_page: https://sweetalert.js.org/docs (fetched 2026-08-29T07:56:03.689588+00:00, sha c9320f2e00f8)
  - registry_npm: https://registry.npmjs.org/sweetalert (fetched 2026-08-29T07:56:03.691963+00:00, sha 17469fe80b8d)
- Data as of 2026-08-30T08:39:29.467469+00:00.
