mirror of
https://github.com/alrayyes/wiki.git
synced 2025-05-24 00:29:01 +00:00
Revert "perf: eagerly compute explorer nodes to avoid re-render in memoized value"
This reverts commit 16a9caa555
.
This commit is contained in:
parent
4aaeb768d8
commit
9cefcd0dd1
2 changed files with 45 additions and 44 deletions
quartz/components
|
@ -224,10 +224,15 @@ export function ExplorerNode({ node, opts, fullPath, fileData }: ExplorerNodePro
|
|||
class="content"
|
||||
data-folderul={folderPath}
|
||||
>
|
||||
{node.children.map((childNode) =>
|
||||
// eagerly render children so we can memoize properly
|
||||
ExplorerNode({ node: childNode, opts, fileData, fullPath: folderPath }),
|
||||
)}
|
||||
{node.children.map((childNode, i) => (
|
||||
<ExplorerNode
|
||||
node={childNode}
|
||||
key={i}
|
||||
opts={opts}
|
||||
fullPath={folderPath}
|
||||
fileData={fileData}
|
||||
/>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
</li>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue