Skip to content

Commit 522fd54

Browse files
committed
upgrade deps.. swap kind and scope in sort order
1 parent 3ab31a0 commit 522fd54

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

lib/jsdoc-parse.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ function getStats (jsdocExplainOutput) {
7373
}
7474

7575
function sort (array, sortBy) {
76-
var customSortOrders = {
76+
var customOrder = {
7777
kind: [ 'class', 'constructor', 'mixin', 'member', 'namespace', 'enum',
7878
'constant', 'function', 'event', 'typedef', 'external' ],
7979
scope: [ 'global', 'instance', 'static', 'inner' ]
@@ -82,7 +82,7 @@ function sort (array, sortBy) {
8282
if (!sortBy) {
8383
return array
8484
} else {
85-
return sortArray(array, sortBy, customSortOrders)
85+
return sortArray(array, sortBy, customOrder)
8686
}
8787
}
8888

lib/transform.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -346,7 +346,7 @@ function sort (object, sortFunction) {
346346
}
347347

348348
function sortIdentifier (doclet) {
349-
var fieldOrder = [ 'id', 'parentId', 'longname', 'name', 'scope', 'kind', 'isExported', 'classdesc', 'augments', 'inherits', 'inherited', 'implements', 'overrides', 'mixes', 'description', 'memberof', 'alias', 'params', 'fires', 'examples', 'returns', 'type', 'defaultvalue', 'readonly', 'thisvalue', 'isEnum', 'properties', 'optional', 'nullable', 'variable', 'author', 'deprecated', 'ignore', 'access', 'requires', 'version', 'since', 'licenses', 'license', 'typicalname', 'category', 'see', 'exceptions', 'codeName', 'todoList', 'customTags', 'chainable', 'meta', 'order' ]
349+
var fieldOrder = [ 'id', 'parentId', 'longname', 'name', 'kind', 'scope', 'isExported', 'classdesc', 'augments', 'inherits', 'inherited', 'implements', 'overrides', 'mixes', 'description', 'memberof', 'alias', 'params', 'fires', 'examples', 'returns', 'type', 'defaultvalue', 'readonly', 'thisvalue', 'isEnum', 'properties', 'optional', 'nullable', 'variable', 'author', 'deprecated', 'ignore', 'access', 'requires', 'version', 'since', 'licenses', 'license', 'typicalname', 'category', 'see', 'exceptions', 'codeName', 'todoList', 'customTags', 'chainable', 'meta', 'order' ]
350350
return sort(doclet, function (a, b) {
351351
if (fieldOrder.indexOf(a) === -1 && fieldOrder.indexOf(b) > -1) {
352352
return 1

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
"core-js": "^2.1.0",
2828
"feature-detect-es6": "^1.2.0",
2929
"object-tools": "^2",
30-
"sort-array": "^0.1.0",
30+
"sort-array": "^1.0.0",
3131
"test-value": "^1.0.1",
3232
"typical": "^2.4.2"
3333
},

0 commit comments

Comments
 (0)