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

네트워크 모듈 추가 #2

Closed
enebin opened this issue Jul 13, 2023 · 0 comments · Fixed by #11 or #8
Closed

네트워크 모듈 추가 #2

enebin opened this issue Jul 13, 2023 · 0 comments · Fixed by #11 or #8
Assignees
Labels
enhancement New feature or request module

Comments

@enebin
Copy link
Member

enebin commented Jul 13, 2023

목적

🗣️ 알아서 잘 돌아가는 네트워크 모듈이 있었으면 좋겠어요
...ㅋㅋ

✋ 왜 필요함? 그냥 그때그때 쓰면 안 됨?
내 생각에

  • 네트워크 통신 과정이 한 군데 집중되므로 디버깅하기가 편함 + 로그 수집이 편함
  • (테스트를 하겠다면) 그때그때 썼다가는 네트워크 떼어내는 작업이 고될 수 있음
  • API도 퍼져있는 것보단 한 군데서 매니지하는게 편하지 않을까?
  • 등등

그래서 있었으면 좋겠다~~~ 이 정도면 Moya 쓰는 게 나을 수도

예시

func requestProblem(id: Int) {
    guard let problem = await NetworkModule.request(api: .getProblem(id: id)) else {
        return
    }

    send(problem) // to somewhere like `reducer`
}
@enebin enebin added enhancement New feature or request module TBD and removed TBD labels Jul 13, 2023
@enebin enebin self-assigned this Jul 16, 2023
@enebin enebin linked a pull request Jul 16, 2023 that will close this issue
@enebin enebin closed this as completed Jul 20, 2023
@enebin enebin linked a pull request Jul 20, 2023 that will close this issue
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request module
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant