From 82ddbe1be01ce0bbcd64ef7a4b54ef7ca15bd232 Mon Sep 17 00:00:00 2001 From: Walidoux Date: Fri, 22 Apr 2022 19:06:35 +0000 Subject: [PATCH] refactor(handlebars): implement children for genereated component --- templates/Component/Component.tsx.hbs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/templates/Component/Component.tsx.hbs b/templates/Component/Component.tsx.hbs index 2750b52..0e62b64 100644 --- a/templates/Component/Component.tsx.hbs +++ b/templates/Component/Component.tsx.hbs @@ -4,10 +4,11 @@ import styles from './{{ properCase name }}.module.scss' interface {{ properCase name }}Props { className?: string + children?: React.ReactNode } export const {{ properCase name }}: React.FC<{{ properCase name }}Props> = (props) => { - const { className } = props + const { className, children } = props - return
+ return
{children}
}