我在我的页面https://www.datanumen.com上运行 Google PageSpeed Insight
它报告了以下问题:
我查看我的页面,发现这些根本不是动画,相反,它们只是按钮。当鼠标悬停在它们上时,它们会改变颜色。为什么它们被视为非合成动画以及如何解决这些问题?
根据https://developers.google.com/web/fundamentals/performance/rendering/stick-to-compositor-only-properties-and-manage-layer-count,您必须删除按钮的过渡效果。
a.btn, a.button, .inner-page-contact form button, .testimonial-form-holder button, input[type="button"], input[type="reset"], input[type="submit"] {
/* -webkit-transition: all 0.2s ease-in-out;
-moz-transition: all 0.2s ease-in-out;
-o-transition: all 0.2s ease-in-out;
-ms-transition: all 0.2s ease-in-out;
transition: all 0.2s ease-in-out; */
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句