Open nets-dev opened 3 years ago
@nets-dev Thank you for your comment. Please correct me if I am not wrong, I have to remove the Retrofit library dependency from the API.kt file and manage it inside the RetrofitAPI.kt file. So In the future, if suppose we want to implement another networking library we have to just replace the RetrofitAPI.kt file with the new file. Please let me know if I understood it correctly.
@lnt-nishantdande Yes, you got it 👍
Apply this change in a separate branch and create a pull request. Make sure to add nets-dev
GitHub account as reviewer.
We'll review the rest of the project and raise issues like this if necessary or ask questions in the code.
Can you actively participate by replying to such comments promptly like you have done now?
@nets-dev I have modified the codebase as per the review comment. Please check and review the pull request from the below link - https://github.com/lnt-nishantdande/Practice-Android/pull/2
Third party dependency (in this case Retrofit) must be managed cleanly. The template project contains
API.kt
andRetrofitAPI.kt
to assist in managing Retrofit dependency and limit its use to the concreteRetrofitAPI
implementation. If one chooses to replaceRetrofitAPI
concrete implementation with another concrete implementation e.g. using Ktor, the project should remain unaffected. Keep this in mind and try to clean up the dependency, starting with avoiding any retrofit import inAPI.kt
or any file other thanRetrofitAPI.kt
file. Do you have any question on this? If not, can you confirm if you have understood the point? @lnt-nishantdande