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

Dynamically change enabled value #91

Open
joelambert opened this issue Oct 6, 2020 · 4 comments
Open

Dynamically change enabled value #91

joelambert opened this issue Oct 6, 2020 · 4 comments
Assignees
Labels

Comments

@joelambert
Copy link

Describe the bug
Can't dynamically change the enabled value

To Reproduce
Steps to reproduce the behavior:

  1. Follow instructions in README to change the enabled value from scope data (https://github.com/theomessin/vue-chat-scroll#disable-vue-chat-scroll-using-configuration-prop)

Expected behavior
To be able to change the enabled value reactively.

Additional context
It appears that when following the docs and appending : to the directive, it doesn't load at all. Without this the directive loads but the config value is not reactive.

Any help much appreciated, thanks for the great utility!

@gsusmonzon
Copy link

@joelambert what i did was to bind the whole configuration object as a data property:

<ul class="messages" :v-chat-scroll="scrollOptions">

and

data() => {
  scrollOptions: { enabled: true, always: false, smooth: false, notSmoothOnInit: true },
},

It seemed to work

@FrontLeejonghun
Copy link

@gsusmonzon it's same not working.
that code r u working?

@DOCHIS
Copy link

DOCHIS commented Sep 14, 2021

it's same not working.

@chiragparekh
Copy link

chiragparekh commented Nov 16, 2021

I am having same issue, data is not reactive. Is there any way I can fix this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants