{"id":13392529,"url":"https://github.com/t4t5/sweetalert","last_synced_at":"2026-10-18T21:10:34.599Z","repository":{"id":21318547,"uuid":"24635156","full_name":"t4t5/sweetalert","owner":"t4t5","description":"A beautiful replacement for JavaScript's \"alert\"","archived":false,"fork":false,"pushed_at":"2023-04-15T22:54:03.000Z","size":5478,"stargazers_count":22250,"open_issues_count":200,"forks_count":2743,"subscribers_count":439,"default_branch":"master","last_synced_at":"2026-10-11T18:40:48.075Z","etag":null,"topics":["alert","dialog","javascript","modal","popup","sweetalert","ui"],"latest_commit_sha":null,"homepage":"https://sweetalert.js.org","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/t4t5.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2014-09-30T11:12:48.000Z","updated_at":"2026-10-11T02:53:02.000Z","dependencies_parsed_at":"2022-07-12T15:18:01.653Z","dependency_job_id":"98ff6d3e-cbe2-4267-a0c6-105acdff5675","html_url":"https://github.com/t4t5/sweetalert","commit_stats":{"total_commits":257,"total_committers":72,"mean_commits":"3.5694444444444446","dds":"0.47859922178988323","last_synced_commit":"d927c9bbc66bd26380dc360a71e1876d284a7faf"},"previous_names":[],"tags_count":34,"template":false,"template_full_name":null,"purl":"pkg:github/t4t5/sweetalert","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/t4t5%2Fsweetalert","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/t4t5%2Fsweetalert/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/t4t5%2Fsweetalert/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/t4t5%2Fsweetalert/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/t4t5","download_url":"https://codeload.github.com/t4t5/sweetalert/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/t4t5%2Fsweetalert/sbom","scorecard":{"id":864836,"data":{"date":"2025-08-18","repo":{"name":"github.com/t4t5/sweetalert","commit":"d927c9bbc66bd26380dc360a71e1876d284a7faf"},"scorecard":{"version":"v5.2.1-41-g40576783","commit":"40576783fda6698350fcbbeaea760ff827433034"},"score":2.7,"checks":[{"name":"Code-Review","score":7,"reason":"Found 11/15 approved changesets -- score normalized to 7","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#dangerous-workflow"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#security-policy"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE.md:0","Info: FSF or OSI recognized license: MIT License: LICENSE.md:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#branch-protection"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#fuzzing"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 27 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"186 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-v88g-cgmw-v5xw","Warn: Project is vulnerable to: GHSA-whgm-jr23-g3j9","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-fwr7-v2mv-hh25","Warn: Project is vulnerable to: GHSA-8w4h-3cm3-2pm2","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-pp7h-53gx-mx7r","Warn: Project is vulnerable to: GHSA-qwcr-r2fm-qrc7","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-cwfw-4gq5-mrqx","Warn: Project is vulnerable to: GHSA-g95f-p29q-9xw4","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-x9w5-v3q2-3rhw","Warn: Project is vulnerable to: GHSA-hc9w-4p87-j549","Warn: Project is vulnerable to: GHSA-wg6g-ppvx-927h","Warn: Project is vulnerable to: GHSA-257v-vj4p-3w2h","Warn: Project is vulnerable to: GHSA-g74r-ffvr-5q9f","Warn: Project is vulnerable to: GHSA-3fw8-66wf-pr7m","Warn: Project is vulnerable to: GHSA-6w62-83g6-rfhj","Warn: Project is vulnerable to: GHSA-rch9-xh7r-mqgw","Warn: Project is vulnerable to: GHSA-pxg6-pf52-xh8x","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-rq8g-5pc5-wrhr","Warn: Project is vulnerable to: GHSA-p28h-cc7q-c4fg","Warn: Project is vulnerable to: GHSA-9vvw-cc9w-f27h","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-hr2v-3952-633q","Warn: Project is vulnerable to: GHSA-h6ch-v84p-w6p9","Warn: Project is vulnerable to: GHSA-r7jx-5m6m-cpg9","Warn: Project is vulnerable to: GHSA-phwq-j96m-2c2q","Warn: Project is vulnerable to: GHSA-ghr5-ch3p-vcr6","Warn: Project is vulnerable to: GHSA-vh7m-p724-62c2","Warn: Project is vulnerable to: GHSA-r9p9-mrjm-926w","Warn: Project is vulnerable to: GHSA-434g-2637-qmqr","Warn: Project is vulnerable to: GHSA-49q7-c7j4-3p7m","Warn: Project is vulnerable to: GHSA-977x-g7h5-7qgw","Warn: Project is vulnerable to: GHSA-f7q4-pwc6-w24p","Warn: Project is vulnerable to: GHSA-fc9h-whq2-v747","Warn: Project is vulnerable to: GHSA-vjh7-7g9h-fjfh","Warn: Project is vulnerable to: GHSA-j4f2-536g-r55m","Warn: Project is vulnerable to: GHSA-r7qp-cfhv-p84w","Warn: Project is vulnerable to: GHSA-4gmj-3p3h-gm8h","Warn: Project is vulnerable to: GHSA-6h5x-7c5m-7cr7","Warn: Project is vulnerable to: GHSA-gpvr-g6gh-9mc2","Warn: Project is vulnerable to: GHSA-cm5g-3pgc-8rg4","Warn: Project is vulnerable to: GHSA-rv95-896h-c2vc","Warn: Project is vulnerable to: GHSA-qw6h-vgh9-j6wx","Warn: Project is vulnerable to: GHSA-qrmc-fj45-qfc2","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-9qj9-36jm-prpv","Warn: Project is vulnerable to: GHSA-8r6j-v8pm-fqw3","Warn: Project is vulnerable to: MAL-2023-462","Warn: Project is vulnerable to: GHSA-xf7w-r453-m56c","Warn: Project is vulnerable to: GHSA-q42p-pg8m-cqh6","Warn: Project is vulnerable to: GHSA-w457-6q6x-cgp9","Warn: Project is vulnerable to: GHSA-62gr-4qp9-h98f","Warn: Project is vulnerable to: GHSA-f52g-6jhx-586p","Warn: Project is vulnerable to: GHSA-2cf5-4w76-r9qv","Warn: Project is vulnerable to: GHSA-3cqr-58rm-57f8","Warn: Project is vulnerable to: GHSA-g9r4-xpmj-mj65","Warn: Project is vulnerable to: GHSA-q2c6-c6pm-g3gh","Warn: Project is vulnerable to: GHSA-765h-qjxv-5f44","Warn: Project is vulnerable to: GHSA-f2jv-r9rf-7988","Warn: Project is vulnerable to: GHSA-44pw-h2cw-w3vq","Warn: Project is vulnerable to: GHSA-jp4x-w63m-7wgm","Warn: Project is vulnerable to: GHSA-c429-5p7v-vgjp","Warn: Project is vulnerable to: GHSA-43f8-2h32-f4cj","Warn: Project is vulnerable to: GHSA-6x33-pw7p-hmpq","Warn: Project is vulnerable to: GHSA-c7qv-q95q-8v27","Warn: Project is vulnerable to: GHSA-qqgx-2p2h-9c37","Warn: Project is vulnerable to: GHSA-7r28-3m3f-r2pr","Warn: Project is vulnerable to: GHSA-r8j5-h5cx-65gg","Warn: Project is vulnerable to: GHSA-p9w8-2mpq-49h9","Warn: Project is vulnerable to: GHSA-w7q9-p3jq-fmhm","Warn: Project is vulnerable to: GHSA-xvf7-4v9q-58w6","Warn: Project is vulnerable to: GHSA-6c3j-c64m-qhgq","Warn: Project is vulnerable to: GHSA-gxr4-xjj5-5px2","Warn: Project is vulnerable to: GHSA-jpcq-cgw6-v4j6","Warn: Project is vulnerable to: GHSA-2pr6-76vf-7546","Warn: Project is vulnerable to: GHSA-8j8c-7jfh-h6hx","Warn: Project is vulnerable to: GHSA-896r-f27r-55mw","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-76p3-8jx3-jpfq","Warn: Project is vulnerable to: GHSA-3rfm-jhwj-7488","Warn: Project is vulnerable to: GHSA-hhq3-ff78-jv3g","Warn: Project is vulnerable to: GHSA-jf85-cpcp-j695","Warn: Project is vulnerable to: GHSA-fvqr-27wr-82fm","Warn: Project is vulnerable to: GHSA-4xc9-xhrj-v574","Warn: Project is vulnerable to: GHSA-x5rq-j2xg-h7qm","Warn: Project is vulnerable to: GHSA-p6mc-m468-83gw","Warn: Project is vulnerable to: GHSA-29mw-wpgm-hmr9","Warn: Project is vulnerable to: GHSA-35jh-r3h4-6jhm","Warn: Project is vulnerable to: GHSA-pp57-mqmh-44h7","Warn: Project is vulnerable to: GHSA-6vfc-qv3f-vr6c","Warn: Project is vulnerable to: GHSA-mg69-6j3m-jvgw","Warn: Project is vulnerable to: GHSA-pxmp-fwjc-4x7q","Warn: Project is vulnerable to: GHSA-4xcv-9jjx-gfj3","Warn: Project is vulnerable to: GHSA-f9cm-qmx5-m98h","Warn: Project is vulnerable to: GHSA-7wpw-2hjm-89gp","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-wrvr-8mpx-r7pp","Warn: Project is vulnerable to: GHSA-hxm2-r34f-qmc5","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-vh95-rmgr-6w4m","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-gwg9-rgvj-4h5j","Warn: Project is vulnerable to: GHSA-w9mr-4mfr-499f","Warn: Project is vulnerable to: GHSA-r683-j2x4-v87g","Warn: Project is vulnerable to: GHSA-5fw9-fq32-wv5p","Warn: Project is vulnerable to: GHSA-9v62-24cr-58cx","Warn: Project is vulnerable to: GHSA-r8f7-9pfq-mjmv","Warn: Project is vulnerable to: GHSA-rp65-9cf3-cjxr","Warn: Project is vulnerable to: GHSA-6394-6h9h-cfjg","Warn: Project is vulnerable to: GHSA-cwx2-736x-mf6w","Warn: Project is vulnerable to: GHSA-v39p-96qg-c8rf","Warn: Project is vulnerable to: GHSA-8v63-cqqc-6r2c","Warn: Project is vulnerable to: GHSA-76c9-3jph-rj3q","Warn: Project is vulnerable to: GHSA-28xh-wpgr-7fm8","Warn: Project is vulnerable to: GHSA-q75g-2496-mxpp","Warn: Project is vulnerable to: GHSA-6fx8-h7jm-663j","Warn: Project is vulnerable to: GHSA-hj48-42vr-x3v9","Warn: Project is vulnerable to: GHSA-9wv6-86v2-598j","Warn: Project is vulnerable to: GHSA-rhx6-c78j-4q9w","Warn: Project is vulnerable to: GHSA-h7cp-r72f-jxh6","Warn: Project is vulnerable to: GHSA-v62p-rq8g-8h59","Warn: Project is vulnerable to: GHSA-566m-qj78-rww5","Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j","Warn: Project is vulnerable to: GHSA-f9cm-p3w6-xvr3","Warn: Project is vulnerable to: GHSA-jjv7-qpx3-h62q","Warn: Project is vulnerable to: GHSA-gqgv-6jq5-jjj9","Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp","Warn: Project is vulnerable to: GHSA-hxcm-v35h-mg2x","Warn: Project is vulnerable to: GHSA-6g33-f262-xjp4","Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6","Warn: Project is vulnerable to: GHSA-rjqq-98f6-6j3r","Warn: Project is vulnerable to: GHSA-mjxr-4v3x-q3m4","Warn: Project is vulnerable to: GHSA-cgfm-xwp7-2cvr","Warn: Project is vulnerable to: GHSA-rm97-x556-q36h","Warn: Project is vulnerable to: GHSA-7mwh-4pqv-wmr8","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg","Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p","Warn: Project is vulnerable to: GHSA-qg8p-v9q4-gh34","Warn: Project is vulnerable to: GHSA-g4rg-993r-mgx7","Warn: Project is vulnerable to: GHSA-fxwf-4rqh-v8g3","Warn: Project is vulnerable to: GHSA-25hc-qcg6-38wj","Warn: Project is vulnerable to: GHSA-xfhh-g9f5-x4m4","Warn: Project is vulnerable to: GHSA-qm95-pgcg-qqfq","Warn: Project is vulnerable to: GHSA-cqmj-92xf-r6r9","Warn: Project is vulnerable to: GHSA-c9g6-9335-x697","Warn: Project is vulnerable to: GHSA-2m39-62fm-q8r3","Warn: Project is vulnerable to: GHSA-mf6x-7mm4-x2g7","Warn: Project is vulnerable to: GHSA-j44m-qm6p-hp7m","Warn: Project is vulnerable to: GHSA-3jfq-g458-7qm9","Warn: Project is vulnerable to: GHSA-5955-9wpr-37jh","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-jgrx-mgxx-jf9v","Warn: Project is vulnerable to: GHSA-g7q5-pjjr-gqvp","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-7p7h-4mm5-852v","Warn: Project is vulnerable to: GHSA-662x-fhqg-9p8v","Warn: Project is vulnerable to: GHSA-394c-5j6w-4xmx","Warn: Project is vulnerable to: GHSA-fhg7-m89q-25r3","Warn: Project is vulnerable to: GHSA-cf4h-3jhx-xvhq","Warn: Project is vulnerable to: GHSA-v2p6-4mp7-3r9v","Warn: Project is vulnerable to: GHSA-pv4c-p2j5-38j4","Warn: Project is vulnerable to: GHSA-46c4-8wrp-j99v","Warn: Project is vulnerable to: GHSA-9m6j-fcg5-2442","Warn: Project is vulnerable to: GHSA-hh27-ffr2-f2jc","Warn: Project is vulnerable to: GHSA-rqff-837h-mm52","Warn: Project is vulnerable to: GHSA-8v38-pw62-9cw2","Warn: Project is vulnerable to: GHSA-hgjh-723h-mx2j","Warn: Project is vulnerable to: GHSA-jf5r-8hm2-f872","Warn: Project is vulnerable to: GHSA-pgr8-jg6h-8gw6","Warn: Project is vulnerable to: GHSA-wr3j-pwj9-hqq6","Warn: Project is vulnerable to: GHSA-cf66-xwfp-gvc4","Warn: Project is vulnerable to: GHSA-4v9v-hfq4-rm2v","Warn: Project is vulnerable to: GHSA-9jgg-88mc-972h","Warn: Project is vulnerable to: GHSA-g78m-2chm-r7qv","Warn: Project is vulnerable to: GHSA-5v72-xg48-5rpm","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q","Warn: Project is vulnerable to: GHSA-72mh-269x-7mh5","Warn: Project is vulnerable to: GHSA-h4j5-c7cj-74xg","Warn: Project is vulnerable to: GHSA-c4w7-xm78-47vh","Warn: Project is vulnerable to: GHSA-p9pc-299p-vxgp"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/40576783fda6698350fcbbeaea760ff827433034/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-24T02:24:17.345Z","repository_id":21318547,"created_at":"2025-08-24T02:24:17.345Z","updated_at":"2025-08-24T02:24:17.345Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":343843146,"owners_count":38212723,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-10-03T21:59:58.778Z","status":"online","status_checked_at":"2026-10-12T02:00:06.297Z","response_time":96,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["alert","dialog","javascript","modal","popup","sweetalert","ui"],"created_at":"2024-07-30T17:00:26.728Z","updated_at":"2026-10-18T21:10:33.981Z","avatar_url":"https://github.com/t4t5.png","language":"TypeScript","funding_links":["https://opencollective.com/SweetAlert"],"categories":["JavaScript","Uncategorized","TypeScript","Web 前端","css","Modals and Popups","Alert","Modals and Popups [🔝](#readme)","19. 通知组件/弹框组件/模态窗口 ##","Web","ui","模态框和弹出框","19. 通知组件/弹框组件/模态窗口","📦 Legacy \u0026 Inactive Projects","Animation","Javascript","Table of Contents"],"sub_categories":["Uncategorized","Other","Save","13.20 视差滚动(Parallax Scrolling) ###","Frontend and UI Components","其它","13.20 视差滚动(Parallax Scrolling)","jQuery plugins","Modals and Popups","Presentational Components"],"readme":"\u003cp align=\"center\"\u003e\n  \u003ca href=\"http://sweetalert.js.org\"\u003e\n    \u003cimg alt=\"SweetAlert\" src=\"https://raw.githubusercontent.com/t4t5/sweetalert/e3c2085473a0eb5a6b022e43eb22e746380bb955/assets/logotype.png\" width=\"300\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  A beautiful replacement for JavaScript's \"alert\"\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://badge.fury.io/js/sweetalert\"\u003e\u003cimg src=\"https://badge.fury.io/js/sweetalert.svg\" alt=\"npm version\" height=\"18\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://travis-ci.org/t4t5/sweetalert\"\u003e\u003cimg src=\"https://travis-ci.org/t4t5/sweetalert.svg\" alt=\"Build status\" /\u003e\u003c/a\u003e\n  \u003ca href=\"https://www.npmjs.com/package/sweetalert\"\u003e\n    \u003cimg src=\"https://img.shields.io/npm/dm/sweetalert.svg\" /\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/t4t5/sweetalert/blob/master/LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/license/t4t5/sweetalert.svg\" /\u003e\n  \u003c/a\u003e \n  \u003ca href=\"#backers\" alt=\"sponsors on Open Collective\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/backers/badge.svg\" /\u003e\u003c/a\u003e \u003ca href=\"#sponsors\" alt=\"Sponsors on Open Collective\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsors/badge.svg\" /\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"A success modal\" src=\"https://raw.githubusercontent.com/t4t5/sweetalert/e3c2085473a0eb5a6b022e43eb22e746380bb955/assets/swal.gif\"\u003e\n\u003c/p\u003e\n\n\n## Installation\n\n```bash\n$ npm install --save sweetalert\n```\n\n## Usage\n\n```javascript\nimport swal from 'sweetalert';\n\nswal(\"Hello world!\");\n```\n\n## Upgrading from 1.X\n\nMany improvements and breaking changes have been introduced in the 2.0 release. Make sure you read the [upgrade guide](https://sweetalert.js.org/guides/#upgrading-from-1x) to avoid nasty surprises!\n\n## Guides\n\n- [Installation](https://sweetalert.js.org/guides/#installation)\n- [Getting started](https://sweetalert.js.org/guides/#getting-started)\n- [Advanced examples](https://sweetalert.js.org/guides/#advanced-examples)\n- [Using with libraries](https://sweetalert.js.org/guides/#using-with-libraries)\n- [Upgrading from 1.X](https://sweetalert.js.org/guides/#upgrading-from-1x)\n\n## Documentation\n\n- [Configuration](https://sweetalert.js.org/docs/#configuration)\n- [Methods](https://sweetalert.js.org/docs/#methods)\n- [Theming](https://sweetalert.js.org/docs/#theming)\n\n## Examples\n\n### An error message:\n```javascript\nswal(\"Oops!\", \"Something went wrong!\", \"error\");\n```\n\n### A warning message, with a function attached to the confirm message:\n  - Using promises:\n  ```javascript\n  swal({\n    title: \"Are you sure?\",\n    text: \"Are you sure that you want to leave this page?\",\n    icon: \"warning\",\n    dangerMode: true,\n  })\n  .then(willDelete =\u003e {\n    if (willDelete) {\n      swal(\"Deleted!\", \"Your imaginary file has been deleted!\", \"success\");\n    }\n  });\n  ```\n  - Using async/await:\n  ```javascript\n  const willDelete = await swal({\n    title: \"Are you sure?\",\n    text: \"Are you sure that you want to delete this file?\",\n    icon: \"warning\",\n    dangerMode: true,\n  });\n\n  if (willDelete) {\n    swal(\"Deleted!\", \"Your imaginary file has been deleted!\", \"success\");\n  }\n  ```\n  \n### A prompt modal, where the user's input is logged:\n  - Using promises:\n  ```javascript\n  swal(\"Type something:\", {\n    content: \"input\",\n  })\n  .then((value) =\u003e {\n    swal(`You typed: ${value}`);\n  });\n  ```\n  - Using async/await:\n  ```javascript\n  const value = await swal(\"Type something:\", {\n    content: \"input\",\n  });\n\n  swal(`You typed: ${value}`);\n  ```\n\n### In combination with Fetch:\n  - Using promises:\n  ```javascript\n  swal({\n    text: \"Wanna log some information about Bulbasaur?\",\n    button: {\n      text: \"Search!\",\n      closeModal: false,\n    },\n  })\n  .then(willSearch =\u003e {\n    if (willSearch) {\n      return fetch(\"http://pokeapi.co/api/v2/pokemon/1\");\n    }\n  })\n  .then(result =\u003e result.json())\n  .then(json =\u003e console.log(json))\n  .catch(err =\u003e {\n    swal(\"Oops!\", \"Seems like we couldn't fetch the info\", \"error\");\n  });\n  ```\n  - Using async/await:\n  ```javascript\n  const willSearch = await swal({\n    text: \"Wanna log some information about Bulbasaur?\",\n    button: {\n      text: \"Search!\",\n      closeModal: false,\n    },\n  });\n  \n  if (willSearch) {\n    try {\n      const result = await fetch(\"http://pokeapi.co/api/v2/pokemon/1\");\n      const json = await result.json();\n      console.log(json);\n    } catch (err) {\n      swal(\"Oops!\", \"Seems like we couldn't fetch the info\", \"error\");\n    }\n  }\n  ```\n\n## Using with React\n\nSweetAlert has tools for [integrating with your favourite rendering library.](https://sweetalert.js.org/guides/#using-with-libraries).\n\nIf you're using React, you can install [SweetAlert with React](https://www.npmjs.com/package/@sweetalert/with-react) in addition to the main library, and easily add React components to your alerts like this:\n\n```javascript\nimport React from 'react'\nimport swal from '@sweetalert/with-react'\n\nswal(\n  \u003cdiv\u003e\n    \u003ch1\u003eHello world!\u003c/h1\u003e\n    \u003cp\u003e\n      This is now rendered with JSX!\n    \u003c/p\u003e\n  \u003c/div\u003e\n)\n```\n\n[Read more about integrating with React](https://sweetalert.js.org/guides/#using-react)\n\n## Contributing\n\n### If you're changing the core library:\n1. Make changes in the `src` folder.\n2. Preview changes by running `npm run docs`\n3. Submit pull request\n\n### If you're changing the documentation:\n1. Make changes in the `docs-src` folder.\n2. Preview changes by running `npm run docs`\n3. Run `npm run builddocs` to compile the changes to the `docs` folder\n4. Submit pull request\n\n## Contributors\n\nThis project exists thanks to all the people who contribute. [[Contribute](https://github.com/t4t5/sweetalert#contributing)].\n\u003ca href=\"https://github.com/t4t5/sweetalert/graphs/contributors\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/contributors.svg?width=890\u0026button=false\" /\u003e\u003c/a\u003e\n\n\n## Backers\n\nThank you to all our backers! 🙏 [[Become a backer](https://opencollective.com/SweetAlert#backer)]\n\n\u003ca href=\"https://opencollective.com/SweetAlert#backers\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/backers.svg?width=890\"\u003e\u003c/a\u003e\n\n\n## Sponsors\n\nSupport this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/SweetAlert#sponsor)]\n\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/0/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/0/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/1/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/1/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/2/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/2/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/3/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/3/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/4/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/4/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/5/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/5/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/6/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/6/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/7/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/7/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/8/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/8/avatar.svg\"\u003e\u003c/a\u003e\n\u003ca href=\"https://opencollective.com/SweetAlert/sponsor/9/website\" target=\"_blank\"\u003e\u003cimg src=\"https://opencollective.com/SweetAlert/sponsor/9/avatar.svg\"\u003e\u003c/a\u003e\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ft4t5%2Fsweetalert","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ft4t5%2Fsweetalert","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ft4t5%2Fsweetalert/lists"}