hilongjw / vue-recyclerview

Mastering Large Lists with the vue-recyclerview
https://hilongjw.github.io/vue-recyclerview/
MIT License
1.45k stars 121 forks source link

Parent component not accessable #16

Open TamerZorba opened 7 years ago

TamerZorba commented 7 years ago

I'am trying to access methods defined on the main component, is it missing or it just the documentation is not completed !!

this should help with global methods for all items.

hilongjw commented 7 years ago

Try this way

<RecyclerView 
      :options="options"
    ></RecyclerView>
data () {
return { 
  options: {
        props: {
          $parent: this
        }
      }
  }
}
TamerZorba commented 7 years ago

i think its not working, i couldn't find any related data inside item object, can you plz describe how to access $parent from (Item) scope.