1
1
mirror of https://github.com/theoludwig/theoludwig.git synced 2025-05-29 22:37:44 +02:00

refactor: avoid usage of React.FC to use JSX.Element (to stay consistent)

This commit is contained in:
2023-08-01 17:22:09 +02:00
parent 4b2e7bae90
commit 2e0138194c
34 changed files with 51 additions and 37 deletions

View File

@ -1,6 +1,6 @@
type SectionHeadingProps = React.ComponentPropsWithRef<'h2'>
export const SectionHeading: React.FC<SectionHeadingProps> = (props) => {
export const SectionHeading = (props: SectionHeadingProps): JSX.Element => {
const { children, ...rest } = props
return (

View File

@ -8,7 +8,7 @@ type SectionProps = React.ComponentPropsWithRef<'section'> & {
withoutShadowContainer?: boolean
}
export const Section: React.FC<SectionProps> = (props) => {
export const Section = (props: SectionProps): JSX.Element => {
const {
children,
heading,