mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 12:29:55 +08:00
chore(docs): alphabetize class members in docs
This commit is contained in:
@ -40,9 +40,22 @@ module.exports = function collectInputsOutputs() {
|
||||
}
|
||||
|
||||
// update doc with pruned members list and add inputs and outputs
|
||||
doc.members = members;
|
||||
doc.inputs = inputs;
|
||||
doc.outputs = outputs;
|
||||
doc.members = members.sort(alphabetize);
|
||||
doc.inputs = inputs.sort(alphabetize);
|
||||
doc.outputs = outputs.sort(alphabetize);
|
||||
}
|
||||
|
||||
function alphabetize(a, b) {
|
||||
if (!a.name) {
|
||||
return 1;
|
||||
} else if (!b.name) {
|
||||
return -1;
|
||||
} else if (a.name < b.name) {
|
||||
return -1;
|
||||
} else if (a.name > b.name) {
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
function parseMember(member) {
|
||||
|
Reference in New Issue
Block a user