本文介绍了是否有任何浏览器的布局引擎,其中除preT SASS本身(不CSS)或插件它使这个?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

想象一下由刚刚的HTML + SASS文件的网站,但就像HTML + CSS浏览器中显示。本质上,跳过第一编译SASS为CSS的步骤。是否有任何(甚至刘海)项目,使这个?

Imagine a site made of just of HTML + SASS files, but displaying in a browser just like HTML + CSS. Essentially, skipping the step of compiling the SASS to CSS first. Is there any (even fringe) project that enables this?

推荐答案

没有,但正在做从萨斯/少动的想法变成标准化的CSS工作。相反,上述意见,也有很好的理由做在客户端的计算。浏览器将能够访问实际的DOM,做更明智的计算。需要百分比增加像素? pre-处理器不能做到这一点,但浏览器可以。

No, but there is work being done to move ideas from Sass/Less into standardized CSS. Contrary to the comments above, there are very good reasons to do the calculation on the client side. Browsers would be able to access the actual DOM, to do more informed calculations. Need to add percentages to pixels? Pre-processors can't do that, but a browser could.

在事实上,这是可以在浏览器中直接实现萨斯你不想要的原因。萨斯是真棒,但如果浏览器实现类似的功能,应通过与DOM整合进一步将这些创意。这与并简单的。不能等待更多!

In fact, that's the reason you don't want Sass to be implemented in a browser directly. Sass is awesome, but if browsers are implementing similar features, they should take those ideas even further by integrating with the DOM. That's happening now with variables and simple calculations. Can't wait for more!

这篇关于是否有任何浏览器的布局引擎,其中除preT SASS本身(不CSS)或插件它使这个?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-06 05:08