Skip to content

Commit

Permalink
minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
JKobrynski committed Oct 31, 2023
1 parent 8687ed3 commit 6a15a2d
Showing 1 changed file with 10 additions and 14 deletions.
24 changes: 10 additions & 14 deletions src/components/UnorderedList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,19 @@ import Text from './Text';

type UnorderedListProps = {
/** An array of strings to display as an unordered list */
items: string[];
items?: string[];
};

function UnorderedList({items = []}: UnorderedListProps) {
return (
<>
{items.map((itemText) => (
<View
key={itemText}
style={[styles.flexRow, styles.alignItemsStart, styles.ml2]}
>
<Text style={[styles.mr2]}>{'\u2022'}</Text>
<Text>{itemText}</Text>
</View>
))}
</>
);
return items.map((itemText) => (
<View
key={itemText}
style={[styles.flexRow, styles.alignItemsStart, styles.ml2]}
>
<Text style={[styles.mr2]}>{'\u2022'}</Text>
<Text>{itemText}</Text>
</View>
));
}

UnorderedList.displayName = 'UnorderedList';
Expand Down

0 comments on commit 6a15a2d

Please sign in to comment.