Skip to content

Commit

Permalink
Use $el instead of refs
Browse files Browse the repository at this point in the history
  • Loading branch information
mercs600 committed Oct 28, 2020
1 parent 3c20c9e commit eac43e5
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/Scrollbar.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export default {
methods: {
create () {
if (!(this.ps && this.$isServer)) {
this.ps = new PerfectScrollbar(this.$refs.container, this.options)
this.ps = new PerfectScrollbar(this.$el, this.options)

eventNames.forEach(eventName => {
this.ps.element.addEventListener(eventName, event => this.$emit(eventName, event))
Expand Down Expand Up @@ -97,7 +97,6 @@ export default {
render () {
return h(this.tag,
{
ref: 'container',
class: 'ps'
},
this.$slots.default && this.$slots.default())
Expand Down

0 comments on commit eac43e5

Please sign in to comment.