Problem: To Implement Pagination on the server side using Ktor and Kmongo.
Tech Stacks:
Kotlin as Programming Language.
Ktor as Web Framework.
MongoDb as database.
Kmongo as Sql framework.
I cannot find any tutorial or posts that describes to implement pagination with Database in Ktor.
This is how I implemented the same.
Thanks to @Aleksei Tirman.
For More see - https://stackoverflow.com/a/15387497/13963150