本文介绍了你建议不要基于javascript的LESS吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我,我对尝试显示的LESS.js方法非常感兴趣。

After I watched this NetTUTs video, I'm very interested in trying out the LESS.js method shown.

除了明显的,什么如果用户没有启用javascript?或会有一个小的性能损失......是否有这个原因不能在生产中使用?

Other than the obvious, "What if the user doesn't have javascript enabled?", or "There's going to be a small performance hit"... is there a reason this cannot be used in production?

LESS本质上看起来应该是什么样的CSS ...

LESS essentially looks like what CSS should be...

推荐答案

我看不出有什么理由用于生产。将它作为构建脚本运行更有意义,然后在缓存的无cookie域上使输出(常规CSS)可用。然后,它在没有JavaScript的情况下工作正常,并且在每次页面加载时都不需要JavaScript处理(这将比调整的本机代码中编写的CSS解析器慢)。

I can't see any reason why it should be used in production. It makes more sense to run this as a build script, then make the output (regular CSS) available on a cached cookie-free domain. Then, it works fine without JavaScript and doesn't require JavaScript processing (which will be slower than the CSS parsers written in tuned native code) on every page load.

这篇关于你建议不要基于javascript的LESS吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-21 23:24