Galerie und tage
This commit is contained in:
22
node_modules/sort-keys-length/index.js
generated
vendored
22
node_modules/sort-keys-length/index.js
generated
vendored
@@ -1,22 +0,0 @@
|
||||
'use strict';
|
||||
|
||||
var sortKeys = require('sort-keys');
|
||||
|
||||
/**
|
||||
* Sort object keys by length
|
||||
*
|
||||
* @param obj
|
||||
* @api public
|
||||
*/
|
||||
|
||||
module.exports.desc = function (obj) {
|
||||
return sortKeys(obj, function (a, b) {
|
||||
return b.length - a.length;
|
||||
});
|
||||
}
|
||||
|
||||
module.exports.asc = function (obj) {
|
||||
return sortKeys(obj, function (a, b) {
|
||||
return a.length - b.length;
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user