created () { // this.footerAuto(); $(function() { footerAuto(); }) function footerAuto() { var _wh = $(window).height(); var _dh = $(document).height(); var _bh = $(document.body).height(); if (_bh < _wh) { $(".footer").css({ position: "fixed", bottom: "0", left: "0", }) } else { $(".footer").css({ position: "static", bottom: "auto", left: "auto", }) } } }
vue项目中当网站内容不足一屏时footer如何紧贴底部
猜你喜欢
转载自blog.csdn.net/weixin_40292626/article/details/79885237
今日推荐
周排行