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

[Feat/week8] clean architecture #12

Merged
merged 37 commits into from
Jan 14, 2024
Merged

Conversation

chanubc
Copy link
Contributor

@chanubc chanubc commented Jan 3, 2024

πŸ“Œπ˜π˜΄π˜΄π˜Άπ˜¦π˜΄

  • closed #

πŸ“Žπ˜žπ˜°π˜³π˜¬ π˜‹π˜¦π˜΄π˜€π˜³π˜ͺ𝘱𝘡π˜ͺ𝘰𝘯

  • data, domain, uiμ˜μ—­ 뢄리
  • μ˜μ‘΄μ„± μˆ˜λ™ μ£Όμž…
  • uistate uitl둜 λ³€κ²½

πŸ“·π˜šπ˜€π˜³π˜¦π˜¦π˜―π˜΄π˜©π˜°π˜΅

πŸ’¬π˜›π˜° π˜™π˜¦π˜·π˜ͺ𝘦𝘸𝘦𝘳𝘴

μ†Œν˜„μ•„ μ‚΄λ €μ€˜

디렉토리 [data-datasourceimpl-remote]
[chore] : rename
@chanubc chanubc added βž•Β [ADD] λΆ€μˆ˜μ μΈ μ½”λ“œ μΆ”κ°€ 및 라이브러리 μΆ”κ°€, μƒˆλ‘œμš΄ 파일 생성  ♻️ [REFACTOR] μ½”λ“œ λ¦¬νŒ©ν† λ§ ⭐ [FEAT] μƒˆλ‘œμš΄ κΈ°λŠ₯ κ΅¬ν˜„ βœ…Β [MOD] μ½”λ“œ μˆ˜μ • 및 λ‚΄λΆ€ 파일 μˆ˜μ • labels Jan 3, 2024
@chanubc chanubc requested review from Eonji-sw, sohyun127 and a team January 3, 2024 09:21
@chanubc chanubc self-assigned this Jan 3, 2024
Copy link

@sohyun127 sohyun127 left a comment

Choose a reason for hiding this comment

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

λ„ˆλ¬΄λ„ˆλ¬΄ κ³ μƒν•˜μ…¨μŠ΅λ‹ˆλ‹€!!!! μΏΌμΉ΄ν–„ 폼미
νŒ¨ν‚€μ§€ 뢄리 λ„ˆλ¬΄ μž˜ν•˜μ…¨λŠ”λ””μš”?!

Comment on lines +16 to +17
private const val AUTH_BASE_URL = BuildConfig.AUTH_BASE_URL
private const val USER_BASE_URL = BuildConfig.USER_BASE_URL

Choose a reason for hiding this comment

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

넀이밍이 λ˜‘κ°™μ€λ° λ³€μˆ˜λ₯Ό 선언해쀄 μ΄μœ κ°€ μžˆμ„κΉŒμš”??

Comment on lines +11 to +13
override suspend fun getReqresList(page: Int): ResponseReqresDto {
return reqresService.getUserList(page)
}

Choose a reason for hiding this comment

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

Suggested change
override suspend fun getReqresList(page: Int): ResponseReqresDto {
return reqresService.getUserList(page)
}
override suspend fun getReqresList(page: Int): ResponseReqresDto = reqresService.getUserList(page)

μš”κΈ°λ„ μœ„μ—λž‘ 톡일성 있게!

is LoginState.Error -> toast("둜그인 μ‹€νŒ¨")
is LoginState.Loading -> toast("둜그인 쀑")
is UiState.Error -> toast("둜그인 μ‹€νŒ¨")
is UiState.Loading -> {}

Choose a reason for hiding this comment

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

Suggested change
is UiState.Loading -> {}
is UiState.Loading -> Unit

μš”λ ‡κ²Œλ„ μž‘μ„± κ°€λŠ₯!

Log.d("server", it.code().toString())
authRepository.login(UserRequestEntity(id, password))
.onSuccess {
_loginState.emit(UiState.Success(it))

Choose a reason for hiding this comment

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

viewModelμ—μ„œ 데이터λ₯Ό 생산(emit)ν•΄μ£Όμ‹  μ΄μœ κ°€ μžˆμ„κΉŒμš”?!

Copy link

@sohyun127 sohyun127 left a comment

Choose a reason for hiding this comment

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

μΆ”κ°€ 확인~~

}
}

private fun observeSignUpState(userEntity: User) {
private fun observeSignUpState() {
lifecycleScope.launch {
viewModel.signUpState.collect {

Choose a reason for hiding this comment

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

그리고 flowWithLifecycle에 λŒ€ν•΄μ„œ 곡뢀해보면 쒋을 것 κ°™μ•„μš”!
(νžŒνŠΈλŠ” StateFlowλŠ” lifecycle을 μžλ™μœΌλ‘œ μ²˜λ¦¬ν•˜μ§€ μ•Šμ•„μ„œ μˆ˜λ™μœΌλ‘œ flow의 collect μ€‘μ§€μ‹œμΌœμ£Όμ–΄μ•Όν•΄μš”!)

@codingmy
Copy link

codingmy commented Jan 6, 2024

클린아킀텍쳐 잘 λ³΅μŠ΅ν•˜κ³  κ°‘λ‹ˆλ‹€μš”~~! ν™”μ΄νŒ…~!!!

Copy link

@m6z1 m6z1 left a comment

Choose a reason for hiding this comment

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

좔후에 클린 아킀텍쳐 곡뢀할 λ•Œ μ½”λ“œ λ³΄κ² μŠ΅λ‹ˆλ‹€ LGTM

@chanubc chanubc merged commit 81a9e85 into develop Jan 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
βž•Β [ADD] λΆ€μˆ˜μ μΈ μ½”λ“œ μΆ”κ°€ 및 라이브러리 μΆ”κ°€, μƒˆλ‘œμš΄ 파일 생성 ⭐ [FEAT] μƒˆλ‘œμš΄ κΈ°λŠ₯ κ΅¬ν˜„ βœ…Β [MOD] μ½”λ“œ μˆ˜μ • 및 λ‚΄λΆ€ 파일 μˆ˜μ •  ♻️ [REFACTOR] μ½”λ“œ λ¦¬νŒ©ν† λ§
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants