hexo/node_modules/stylus/lib/functions/push.js

19 lines
405 B
JavaScript
Raw Normal View History

2023-10-03 11:14:36 +08:00
var utils = require('../utils');
/**
* Push the given args to `expr`.
*
* @param {Expression} expr
* @param {Node} ...
* @return {Unit}
* @api public
*/
(module.exports = function(expr){
expr = utils.unwrap(expr);
for (var i = 1, len = arguments.length; i < len; ++i) {
expr.nodes.push(utils.unwrap(arguments[i]).clone());
}
return expr.nodes.length;
}).raw = true;