title: How to call api on recyclerview item click event in MVVM structure?
body: <p>I am creating Adapter (for Recyclerview) using MVVM structure in Android, where I have created ViewModel class for each item of recyclerview.
  now I want to call an API on Onclick() method of recyclerview in android.</p>
  
  <p>I cannot call API in recyclerview's itemViewModel so i have to call the api using Activity view Model.</p>
  
  <p>what is the best way to do this?</p>
  
  <p>i am following this example on git:
  <a href="https://github.com/MindorksOpenSource/android-mvvm-architecture/tree/master/app/src/main/java/com/mindorks/framework/mvvm" rel="nofollow noreferrer">https://github.com/MindorksOpenSource/android-mvvm-architecture/tree/master/app/src/main/java/com/mindorks/framework/mvvm</a></p>