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: BindingFragment에서 analytics 가능하게 수정 #697

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

haeum808
Copy link
Contributor

🚩 연관 이슈

close #554


📝 작업 내용

  • BindingFragment에서 FirebaseAnalytics 가지고 있게 변경

🏞️ 스크린샷 (선택)


🗣️ 리뷰 요구사항 (선택)

Copy link
Contributor

@aprilgom aprilgom left a comment

Choose a reason for hiding this comment

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

부지런하네요 해음


abstract class BindingFragment<T : ViewDataBinding>(
@LayoutRes private val layoutRes: Int,
) : Fragment() {
private var _binding: T? = null
protected val binding: T
get() = requireNotNull(_binding)
private val analyticsHelper: AnalyticsHelper by lazy {
Copy link
Contributor

Choose a reason for hiding this comment

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

private로 해두면 BindingFragment를 상속받는 Fragment들이 analyticsHelper를 못쓸 것 같아요

Copy link
Contributor

Choose a reason for hiding this comment

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

이 친구도 hilt로 주입받아보는건 어떤가요 모듈 만들어놓은거로

Copy link
Contributor

Choose a reason for hiding this comment

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

BindingActivity에도 이 코드가 있나요

Copy link
Contributor Author

Choose a reason for hiding this comment

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

hilt로 주입하려고 했는데 타입 파라미터를 알 수 없는 곳에는 못한다고 하네요ㅜㅡㅜ

Copy link
Contributor Author

Choose a reason for hiding this comment

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

BindingActivity에는 없습니다.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

analyticsHelper에 있는 private 제거하겠습니다

Copy link
Contributor

@kimhm0728 kimhm0728 left a comment

Choose a reason for hiding this comment

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

좋네요!!

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

Successfully merging this pull request may close these issues.

fix: BindingFragment에서 analytics 가능하게 수정
3 participants