Closed hjin-me closed 9 years ago
例如
.x { .padding-rem(10px) }
可以考虑用
.x { .padding: rem(10px); }
既然已经用了 autoprefix 插件了,再多一个应该也无妨吧。 相关插件: https://www.npmjs.com/package/less-plugin-functions
Autoprefixer 目前还是可选的,而且并不是 est 提供的功能。目前的状态是保持不使用插件仍然可用,所以 est 本身的 Less 代码没有调用任何必须使用插件的功能。
less-plugin-functions 目前只是一个实验性的项目,它希望能增强 Less 的 DSL 以在语言内部实现自定义方法。如果想使用我建议也是在 est 之外来干这个事情。
less-plugin-functions
那就 close 吧。less 不支持自定义函数好郁闷。
例如
可以考虑用
既然已经用了 autoprefix 插件了,再多一个应该也无妨吧。 相关插件: https://www.npmjs.com/package/less-plugin-functions