File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -119,7 +119,7 @@ V Reactu se často používá alternativní způsob zápisu funkce, a to pomocí
119
119
Tento kód je (až na malé rozdíly, ktefé pro teď ignorujeme) ekvivalentí zápisu výše.
120
120
121
121
``` jsx
122
- const Search = > () {
122
+ const Search = () => {
123
123
return (
124
124
< div> Search< / div>
125
125
);
@@ -129,13 +129,13 @@ const Search => () {
129
129
Zanořování (skládání) komponent:
130
130
131
131
``` jsx
132
- const SearchButton = > () {
132
+ const SearchButton = () => {
133
133
return (
134
134
< button>< i className= " search-icon" / > Search< / button>
135
135
);
136
136
}
137
137
138
- const Search = > () {
138
+ const Search = () => {
139
139
return (
140
140
< input placeholder= " search" / >
141
141
< SearchButton / >
@@ -451,7 +451,7 @@ this.state = {loading: true};
451
451
* hook*
452
452
453
453
``` jsx
454
- const Search = > () {
454
+ const Search = () => {
455
455
456
456
const [searchText , setSearchText ] = useState (' abc' );
457
457
You can’t perform that action at this time.
0 commit comments