Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: change Paper, ContentArea chileren type to ReactElementChildren #914

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

YimJiYoung
Copy link
Contributor

Paper나 ContentArea 내에 여러 요소를 렌더링하려면 VStack이나 Fragment로 감싸줘야하는 번거로움이 있어서 children 타입을 허용해줍니다

@YimJiYoung YimJiYoung requested a review from a team December 5, 2023 03:41
Copy link

vercel bot commented Dec 5, 2023

@YimJiYoung is attempting to deploy a commit to the Class101 Team on Vercel.

To accomplish this, @YimJiYoung needs to request access to the Team.

Afterwards, an owner of the Team is required to accept their membership request.

If you're already a member of the respective Vercel Team, make sure that your Personal Vercel Account is connected to your GitHub account.

import { withVariation } from '@vibrant-ui/core';

export type ContentAreaProps = {
padding?: ResponsiveValue<boolean>;
children: ReactElementChild;
children: ReactElementChildren;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

근데 여러 요소면 Stack으로 명시적으로 감싸자고 해서 의도된거 아니였나용?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

그렇긴한데 뷰가 중첩되는게 조금 걸려서 .. 기본으로 수직으로 쌓이니 VStack의 경우는 생략해서 쓰고 싶은 마음이 ..

에러가 나는 경우가 아니라면 타입은 좀 더 열려있어도 되지 않을까 하는 생각을 해보았어요

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

근데 Paper나 ContentArea를 너무 VStack처럼 쓰게 되지 않을까요?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants