Skip to content

Commit 41a4289

Browse files
authored
fix: App.tsx types and indentation (#196)
* fix: App.tsx closes #195 * fix: use React.FC
1 parent 739f9e7 commit 41a4289

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

template/App.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
*/
1010

1111
import React from 'react';
12-
import type {Node} from 'react';
1312
import {
1413
SafeAreaView,
1514
ScrollView,
@@ -28,7 +27,9 @@
2827
ReloadInstructions,
2928
} from 'react-native/Libraries/NewAppScreen';
3029

31-
const Section = ({children, title}): Node => {
30+
const Section: React.FC<{
31+
title: string;
32+
}> = ({children, title}) => {
3233
const isDarkMode = useColorScheme() === 'dark';
3334
return (
3435
<View style={styles.sectionContainer}>
@@ -54,7 +55,7 @@
5455
);
5556
};
5657

57-
const App: () => Node = () => {
58+
const App = () => {
5859
const isDarkMode = useColorScheme() === 'dark';
5960

6061
const backgroundStyle = {

0 commit comments

Comments
 (0)