Skip to content

v-on seems to not be able to bind to events with names containing periods #438

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

Closed
cdrubin opened this issue Sep 19, 2014 · 4 comments
Closed

Comments

@cdrubin
Copy link

cdrubin commented Sep 19, 2014

Bootstrap 3 fires events with names like:

  show.bs.collapse

but vue complains with "Error parsing expression" when encountering something like:

  <div v-on="show.bs.collapse: method_call">
@yyx990803
Copy link
Member

Thanks! Fixed in both dev and next.

@ryanmortier
Copy link

@yyx990803 This doesn't appear to work still?

@hidden.bs.modal="resetSource()" will still fail to trigger the event.

@yyx990803
Copy link
Member

@ryanmortier this conflicts with the modifier syntax introduced in 1.0. Do not use periods in event names.

@tolbxela
Copy link

tolbxela commented Oct 16, 2020

There are cases, for example if you use some library, when you can't change the event name.
Check my question at StackOverflow: Unable to catch an event with a point in name using “v-on”

I guess, it should be possible to handle such events in the right way. If the event modifier after dot is not known, just to pass event further.

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

No branches or pull requests

4 participants