refactor: renameprintList to printHeritageList (#13645)
* Reanem `printList` to `printHeritageList` * Rename
This commit is contained in:
1 parent
6d7abe46e2
commit
a5bd5579cb
1 file changed
+4
-4
@@ -78,12 +78,12 @@ function printClass(path, options, print) {
|
||||
extendsParts.push(" ", printedWithComments);
|
||||
}
|
||||
} else {
|
||||
extendsParts.push(printList(path, options, print, "extends"));
|
||||
extendsParts.push(printHeritageClauses(path, options, print, "extends"));
|
||||
}
|
||||
|
||||
extendsParts.push(
|
||||
printList(path, options, print, "mixins"),
|
||||
printList(path, options, print, "implements")
|
||||
printHeritageClauses(path, options, print, "mixins"),
|
||||
printHeritageClauses(path, options, print, "implements")
|
||||
);
|
||||
|
||||
if (groupMode) {
|
||||
@@ -128,7 +128,7 @@ function shouldIndentOnlyHeritageClauses(node) {
|
||||
);
|
||||
}
|
||||
|
||||
function printList(path, options, print, listName) {
|
||||
function printHeritageClauses(path, options, print, listName) {
|
||||
const { node } = path;
|
||||
if (!isNonEmptyArray(node[listName])) {
|
||||
return "";
|
||||
|
||||
Reference in new issue
Block a user