react-app中引入loading加载动画,刷新页面出现动画

1. 在 public/css 文件里 新建 loading.min.css  文件 写入如下代码:

#i-loading{background:#fff;left:0;top:0;right:0;bottom:0;position:fixed;z-index:9999;transition:all .5s ease-out}.i-loading-out{opacity:0;}#i-loading .loading-center{position:absolute;left:50%;top:50%;height:150px;width:150px;margin-top:-75px;margin-left:-75px;-ms-transform:rotate(45deg);-webkit-transform:rotate(45deg);transform:rotate(45deg)}#i-loading i{width:20px;height:20px;background-color:#2593fb;position:absolute;left:65px;top:65px}#i-loading i:nth-child(2n+0){margin-right:0}#i-loading i:nth-child(1){-webkit-animation:item_one 2s infinite;animation:item_one 2s infinite;-webkit-animation-delay:.2s;animation-delay:.2s}#i-loading i:nth-child(2){-webkit-animation:item_two 2s infinite;animation:item_two 2s infinite;-webkit-animation-delay:.3s;animation-delay:.3s}#i-loading i:nth-child(3){-webkit-animation:item_three 2s infinite;animation:item_three 2s infinite;-webkit-ani
  • 1
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值