我是第一次使用 Prepros 预处理器,我的 less 文件中有以下 mixin。
.mq_max(@max_width; @rules) {
@media only screen and (max-width: @max_width) {
@rules();
}
}
我在我的 less 文件中这样调用它
.mq_max(1366px {
// My code
});
当我用 Koala 编译它时,它总是工作正常,但是当我使用 Prepros 尝试它时,我收到这个错误
no matching destination was found for '.mq_max(1366px)'
知道我在这里做错了什么吗?
最佳答案
将此添加到您的 Less 文件中:
@mixin name {
color: red;
font-size: 25px;
font-weight: bold;
border: 1px solid blue;
}
.selector {
@include name;
}
关于css - Prepros 预处理器不编译 mixins,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59082326/