0
我有一個mixin我創造了在更短的生成網格:LESS遞歸循環:沒有找到匹配的定義
/*Grid*/
@num-cols: 12;
@rowWidth: 100%;
@container-lateral-padding: 1em;
@col-margin-right: 3.8%;
@col-unit: (@rowWidth + @col-margin-right)/@num-cols;
@col-identifier: "col";
@col-identifier-nums: false;
@col-identifier-names: true;
@column-selector-number-at-end: false;
@column-selector-number-at-beginning: true;
.setGrid(@index) when (@index > 1), (@column-selector-number-at-end == false) {
(~"[email protected]{index}[email protected]{colNotation}") {
width: @col-unit * @index - @col-margin-right;
}
.setGrid(@index - 1);
}
.setGrid(0) {}
.setGrid(@num-cols);
但我會得到錯誤:
No matching definition was found for
.setGrid()
我在做什麼這裏錯了嗎?