jquery - 如何在jquery中为图像onclick添加给定的爆炸效果
问题描述
我有一个代码,其中有一个image
in img tag
,
我有一个code for explode
图像....
我want to add this explode effect for onclick of image
。
如何在 jquery 中将这种爆炸效果添加到图像 onclick...
$("img").explode();
$("img").explode({
omitLastLine = false,
radius = 80,
minRadius = 20,
release = true,
fadeTime = 300,
recycle = true,
recycleDelay = 500,
fill = true,
explodeTime = 300,
maxAngle = 360,
gravity = 0,
round = false,
groundDistance = 400,
ignoreCompelete = false,
land=true,
checkOutBound,
finish,
});
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="//code.jquery.com/jquery-3.1.0.min.js"></script>
<!-- <script src="dist/jquery.imgexplode.min.js"></script>-->
<script src="jquery.imgexplode.js"></script>
<img src="https://picsum.photos/200/300" />
解决方案
推荐阅读
- reactjs - 如何从 react-create-app 创建一个捆绑文件
- python - 使用列表作为索引的 Pythonic 方式(没有 numpy)
- ios - 更新整个 pList 数组 - 快速
- node.js - 从一个数据库解析读取并写入事务中的另一个数据库
- c++ - 通过非阻塞套接字使用accept() 获取客户端连接
- php - 移动到其他服务器后管理面板中的 Prestashop FatalErrorException
- encoding - 在 Powershell 中,如何选择字符串的不同部分并将它们分别输出到变量并在行中显示?
- javascript - D3 V3 堆积条形负值
- javascript - 对 oop 使用 remove 事件侦听器
- python - Visual Studio Code pylint 在 Ubuntu 上不起作用