先安装依赖
npm install --save baffle
引入baffle依赖包
import baffle from "baffle";
设置dom混淆与显示
const b = baffle("span", {
characters: "░░▓ ░█▒▒▓ ██▒█ █░ ▓▓▓░ ██░░ ███ ██▓",
speed: 75
});
b.reveal(1000);
官方文档
https://camwiegert.github.io/baffle/