Skip to content

[URH-12] useWindowSize 신규 #4

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

Merged
merged 14 commits into from
Jul 9, 2024
Merged

[URH-12] useWindowSize 신규 #4

merged 14 commits into from
Jul 9, 2024

Conversation

foresec
Copy link
Collaborator

@foresec foresec commented Jul 5, 2024

👾 Pull Request

  • 작업명: use-window-size
  • 상태: 신규

1️⃣ Spec

  • 브라우저 창의 너비와 높이를 제공하는 커스텀 훅
  • 딜레이 시간을 매개변수로 받아 지연 제어가 가능하여 과도한 작동 방지
  • default값으로 200ms만큼 지연효과 적용

2️⃣ 변경 사항

  • 변경 사항 없음

3️⃣ 예시 코드

1. 기본 형태(매개변수없음)

 const { width, height } = useWindowSize();

200ms의 delay 효과 적용

2.지연 시간 변경

 const { width, height } = useWindowSize(1000);

1초의 delay효과 적용

3. 지연 시간 미적용

 const { width, height } = useWindowSize(0);

delay효과 미적용

4️⃣ 관련 문서 (선택 사항)

@foresec foresec self-assigned this Jul 5, 2024
Copy link
Member

@bicochan bicochan left a comment

Choose a reason for hiding this comment

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

아주 유용하게 쓰일 것 같은 useWindowSize👍🏻✨ 고생하셨어요 소현 님!

리뷰 확인 부탁드릴게요!

Copy link
Member

@jeongbaebang jeongbaebang left a comment

Choose a reason for hiding this comment

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

멋진 훅이네요. 고생하셨습니다! 😄

Copy link
Member

@bicochan bicochan left a comment

Choose a reason for hiding this comment

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

추가 리뷰 확인 부탁드립니다!

Copy link
Member

@bicochan bicochan left a comment

Choose a reason for hiding this comment

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

고생하셨습니다👍🏻

bicochan

This comment was marked as duplicate.

@foresec foresec merged commit 782f1b5 into master Jul 9, 2024
Copy link
Member

@bicochan bicochan left a comment

Choose a reason for hiding this comment

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

리뷰 웹훅 테스트

@bicochan bicochan deleted the feature/use-window-size branch July 19, 2024 02:19
@foresec foresec changed the title Feature/use-window-size [URH-12] useWindowSize 신규 Jul 19, 2024
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.

3 participants