Sweet Alert
流行っているらしいのでやってみた。
10 Trending projects on GitHub for web developers - 12th March 2021
GitHub
お試し
<script src="https://unpkg.com/sweetalert/dist/sweetalert.min.js"></script>
<button type=“button” onclick="basicSample()">やさしいアラート</button>
<button type=“button” onclick="amazingSample()">すばらしいアラート</button>
function basicSample(){
swal("きをつけてね。");
}
function amazingSample() {
swal({
title: "すばらしい!!",
text: "You clicked the button!",
icon: "success",
});
}
自分用に使いたいときが来たらと思うメモ。
コメント