Skip to content

Commit ca2c258

Browse files
authored
Merge pull request #1944 from MrFlashAccount/remove-unneeded-wrapper
Remove unneeded memo wrapper in the react-compiler-hooks
2 parents d95d62c + 0d4e553 commit ca2c258

File tree

1 file changed

+3
-3
lines changed
  • frameworks/keyed/react-compiler-hooks/src

1 file changed

+3
-3
lines changed

frameworks/keyed/react-compiler-hooks/src/main.jsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { useState, memo } from "react";
1+
import { useState } from "react";
22
import { createRoot } from "react-dom/client";
33
import { buildData } from "./utils";
44

@@ -12,7 +12,7 @@ const Button = ({ id, title, onClick }) => {
1212
);
1313
};
1414

15-
const Row = memo(({ isSelected, item, select, remove }) => {
15+
const Row = ({ isSelected, item, select, remove }) => {
1616
return (
1717
<tr className={isSelected ? "danger" : ""}>
1818
<td className="col-md-1">{item.id}</td>
@@ -27,7 +27,7 @@ const Row = memo(({ isSelected, item, select, remove }) => {
2727
<td className="col-md-6" />
2828
</tr>
2929
);
30-
});
30+
}
3131

3232
const emptyArr = [];
3333

0 commit comments

Comments
 (0)