File tree Expand file tree Collapse file tree 8 files changed +83
-106
lines changed Expand file tree Collapse file tree 8 files changed +83
-106
lines changed Original file line number Diff line number Diff line change 1
1
/* eslint-env browser */
2
2
3
- import React , { StrictMode , unstable_ConcurrentMode as ConcurrentMode } from 'react' ;
3
+ import React , { unstable_ConcurrentMode as ConcurrentMode } from 'react' ;
4
4
import ReactDOM from 'react-dom' ;
5
5
import { createStore } from 'redux' ;
6
6
@@ -56,18 +56,16 @@ const TextBox = () => {
56
56
} ;
57
57
58
58
const App = ( ) => (
59
- < StrictMode >
60
- < ConcurrentMode >
61
- < ReduxProvider store = { store } >
62
- < h1 > Counter</ h1 >
63
- < Counter />
64
- < Counter />
65
- < h1 > TextBox</ h1 >
66
- < TextBox />
67
- < TextBox />
68
- </ ReduxProvider >
69
- </ ConcurrentMode >
70
- </ StrictMode >
59
+ < ConcurrentMode >
60
+ < ReduxProvider store = { store } >
61
+ < h1 > Counter</ h1 >
62
+ < Counter />
63
+ < Counter />
64
+ < h1 > TextBox</ h1 >
65
+ < TextBox />
66
+ < TextBox />
67
+ </ ReduxProvider >
68
+ </ ConcurrentMode >
71
69
) ;
72
70
73
71
ReactDOM . render ( < App /> , document . getElementById ( 'app' ) ) ;
Original file line number Diff line number Diff line change @@ -9,26 +9,23 @@ import Counter from './Counter';
9
9
import Person from './Person' ;
10
10
11
11
const {
12
- StrictMode,
13
12
// @ts -ignore
14
13
unstable_ConcurrentMode : ConcurrentMode ,
15
14
} = React ;
16
15
17
16
const store = createStore ( reducer ) ;
18
17
19
18
const App = ( ) => (
20
- < StrictMode >
21
- < ConcurrentMode >
22
- < ReduxProvider store = { store } >
23
- < h1 > Counter</ h1 >
24
- < Counter />
25
- < Counter />
26
- < h1 > Person</ h1 >
27
- < Person />
28
- < Person />
29
- </ ReduxProvider >
30
- </ ConcurrentMode >
31
- </ StrictMode >
19
+ < ConcurrentMode >
20
+ < ReduxProvider store = { store } >
21
+ < h1 > Counter</ h1 >
22
+ < Counter />
23
+ < Counter />
24
+ < h1 > Person</ h1 >
25
+ < Person />
26
+ < Person />
27
+ </ ReduxProvider >
28
+ </ ConcurrentMode >
32
29
) ;
33
30
34
31
export default App ;
Original file line number Diff line number Diff line change @@ -9,26 +9,23 @@ import Counter from './Counter';
9
9
import Person from './Person' ;
10
10
11
11
const {
12
- StrictMode,
13
12
// @ts -ignore
14
13
unstable_ConcurrentMode : ConcurrentMode ,
15
14
} = React ;
16
15
17
16
const store = createStore ( reducer ) ;
18
17
19
18
const App = ( ) => (
20
- < StrictMode >
21
- < ConcurrentMode >
22
- < ReduxProvider store = { store } >
23
- < h1 > Counter</ h1 >
24
- < Counter />
25
- < Counter />
26
- < h1 > Person</ h1 >
27
- < Person />
28
- < Person />
29
- </ ReduxProvider >
30
- </ ConcurrentMode >
31
- </ StrictMode >
19
+ < ConcurrentMode >
20
+ < ReduxProvider store = { store } >
21
+ < h1 > Counter</ h1 >
22
+ < Counter />
23
+ < Counter />
24
+ < h1 > Person</ h1 >
25
+ < Person />
26
+ < Person />
27
+ </ ReduxProvider >
28
+ </ ConcurrentMode >
32
29
) ;
33
30
34
31
export default App ;
Original file line number Diff line number Diff line change @@ -9,26 +9,23 @@ import Counter from './Counter';
9
9
import Person from './Person' ;
10
10
11
11
const {
12
- StrictMode,
13
12
// @ts -ignore
14
13
unstable_ConcurrentMode : ConcurrentMode ,
15
14
} = React ;
16
15
17
16
const store = createStore ( reducer ) ;
18
17
19
18
const App = ( ) => (
20
- < StrictMode >
21
- < ConcurrentMode >
22
- < ReduxProvider store = { store } >
23
- < h1 > Counter</ h1 >
24
- < Counter />
25
- < Counter />
26
- < h1 > Person</ h1 >
27
- < Person />
28
- < Person />
29
- </ ReduxProvider >
30
- </ ConcurrentMode >
31
- </ StrictMode >
19
+ < ConcurrentMode >
20
+ < ReduxProvider store = { store } >
21
+ < h1 > Counter</ h1 >
22
+ < Counter />
23
+ < Counter />
24
+ < h1 > Person</ h1 >
25
+ < Person />
26
+ < Person />
27
+ </ ReduxProvider >
28
+ </ ConcurrentMode >
32
29
) ;
33
30
34
31
export default App ;
Original file line number Diff line number Diff line change @@ -8,24 +8,21 @@ import { reducer } from './state';
8
8
import Counter from './Counter' ;
9
9
10
10
const {
11
- StrictMode,
12
11
// @ts -ignore
13
12
unstable_ConcurrentMode : ConcurrentMode ,
14
13
} = React ;
15
14
16
15
const store = createStore ( reducer ) ;
17
16
18
17
const App = ( ) => (
19
- < StrictMode >
20
- < ConcurrentMode >
21
- < ReduxProvider store = { store } >
22
- < h1 > Counter</ h1 >
23
- < Counter />
24
- < h1 > Counter</ h1 >
25
- < Counter />
26
- </ ReduxProvider >
27
- </ ConcurrentMode >
28
- </ StrictMode >
18
+ < ConcurrentMode >
19
+ < ReduxProvider store = { store } >
20
+ < h1 > Counter</ h1 >
21
+ < Counter />
22
+ < h1 > Counter</ h1 >
23
+ < Counter />
24
+ </ ReduxProvider >
25
+ </ ConcurrentMode >
29
26
) ;
30
27
31
28
export default App ;
Original file line number Diff line number Diff line change @@ -9,26 +9,23 @@ import Counter from './Counter';
9
9
import Person from './Person' ;
10
10
11
11
const {
12
- StrictMode,
13
12
// @ts -ignore
14
13
unstable_ConcurrentMode : ConcurrentMode ,
15
14
} = React ;
16
15
17
16
const store = createStore ( reducer ) ;
18
17
19
18
const App = ( ) => (
20
- < StrictMode >
21
- < ConcurrentMode >
22
- < ReduxProvider store = { store } >
23
- < h1 > Counter</ h1 >
24
- < Counter />
25
- < Counter />
26
- < h1 > Person</ h1 >
27
- < Person />
28
- < Person />
29
- </ ReduxProvider >
30
- </ ConcurrentMode >
31
- </ StrictMode >
19
+ < ConcurrentMode >
20
+ < ReduxProvider store = { store } >
21
+ < h1 > Counter</ h1 >
22
+ < Counter />
23
+ < Counter />
24
+ < h1 > Person</ h1 >
25
+ < Person />
26
+ < Person />
27
+ </ ReduxProvider >
28
+ </ ConcurrentMode >
32
29
) ;
33
30
34
31
export default App ;
Original file line number Diff line number Diff line change @@ -10,7 +10,6 @@ import Person from './Person';
10
10
11
11
const {
12
12
useState,
13
- StrictMode,
14
13
// @ts -ignore
15
14
unstable_ConcurrentMode : ConcurrentMode ,
16
15
} = React ;
@@ -21,22 +20,20 @@ const store2 = createStore(reducer);
21
20
const App = ( ) => {
22
21
const [ store , setStore ] = useState ( store1 ) ;
23
22
return (
24
- < StrictMode >
25
- < ConcurrentMode >
26
- < div >
27
- < button type = "button" onClick = { ( ) => setStore ( store1 ) } > store1</ button >
28
- < button type = "button" onClick = { ( ) => setStore ( store2 ) } > store2</ button >
29
- < ReduxProvider store = { store } >
30
- < h1 > Counter</ h1 >
31
- < Counter />
32
- < Counter />
33
- < h1 > Person</ h1 >
34
- < Person />
35
- < Person />
36
- </ ReduxProvider >
37
- </ div >
38
- </ ConcurrentMode >
39
- </ StrictMode >
23
+ < ConcurrentMode >
24
+ < div >
25
+ < button type = "button" onClick = { ( ) => setStore ( store1 ) } > store1</ button >
26
+ < button type = "button" onClick = { ( ) => setStore ( store2 ) } > store2</ button >
27
+ < ReduxProvider store = { store } >
28
+ < h1 > Counter</ h1 >
29
+ < Counter />
30
+ < Counter />
31
+ < h1 > Person</ h1 >
32
+ < Person />
33
+ < Person />
34
+ </ ReduxProvider >
35
+ </ div >
36
+ </ ConcurrentMode >
40
37
) ;
41
38
} ;
42
39
Original file line number Diff line number Diff line change @@ -9,26 +9,23 @@ import Counter from './Counter';
9
9
import Person from './Person' ;
10
10
11
11
const {
12
- StrictMode,
13
12
// @ts -ignore
14
13
unstable_ConcurrentMode : ConcurrentMode ,
15
14
} = React ;
16
15
17
16
const store = createStore ( reducer ) ;
18
17
19
18
const App = ( ) => (
20
- < StrictMode >
21
- < ConcurrentMode >
22
- < ReduxProvider store = { store } >
23
- < h1 > Counter</ h1 >
24
- < Counter />
25
- < Counter />
26
- < h1 > Person</ h1 >
27
- < Person />
28
- < Person />
29
- </ ReduxProvider >
30
- </ ConcurrentMode >
31
- </ StrictMode >
19
+ < ConcurrentMode >
20
+ < ReduxProvider store = { store } >
21
+ < h1 > Counter</ h1 >
22
+ < Counter />
23
+ < Counter />
24
+ < h1 > Person</ h1 >
25
+ < Person />
26
+ < Person />
27
+ </ ReduxProvider >
28
+ </ ConcurrentMode >
32
29
) ;
33
30
34
31
export default App ;
You can’t perform that action at this time.
0 commit comments