mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-25 19:01:38 +01:00
Update Sidebar.tsx
This commit is contained in:
@@ -154,7 +154,10 @@ function buildTree(exchanges: HttpExchange[]): TreeNode<SidebarItem> {
|
||||
children: [],
|
||||
draggable: false,
|
||||
};
|
||||
for (const child of trie.children.values()) {
|
||||
const sortedChildren = [...trie.children.values()].sort((a, b) =>
|
||||
a.label.localeCompare(b.label),
|
||||
);
|
||||
for (const child of sortedChildren) {
|
||||
node.children?.push(toTreeNode(child, node, depth + 1));
|
||||
}
|
||||
return node;
|
||||
|
||||
Reference in New Issue
Block a user