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

Why add a wrapper to Moshi? #9

Open
manideepla opened this issue Mar 29, 2020 · 1 comment
Open

Why add a wrapper to Moshi? #9

manideepla opened this issue Mar 29, 2020 · 1 comment

Comments

@manideepla
Copy link

manideepla commented Mar 29, 2020

I'm still new to Ktor, but familiar with Kotlin and Gradle in general.
If we want to use Moshi as a dependency in a Ktor project, why do we add this library instead of the actual one?
What is this library doing exactly?

@alexstyl
Copy link

alexstyl commented Oct 8, 2021

Hi @manideepl. The library is useful as it allows you to use Moshi with the ContentNegotiation feature of ktor.

If you were to use moshi on its own without the use of this (or similar) library, you would have to serialize a response manually and send it back. The library saves you from that work.

PS: I am using the library. I am not a contributor or owner of the repo

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

No branches or pull requests

2 participants