question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Any way to prevent event bubbling (propagation) of v-btn?

See original GitHub issue

Is there any way to prevent the event propagation os a v-btn, when as an activator of a v-menu?

.root(@click="doSomethingOther")
  v-menu(bottom left)
    v-btn(slot="activator")   // When clicking this button, the click event will bubble up to `.root` also...
      v-icon more_vert
    v-list
      v-list-tile
        v-list-tile-title ....

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
KaelWDcommented, Oct 12, 2018

My bad, @click.native.stop

1reaction
KaelWDcommented, Oct 11, 2018

Read the documentation please: https://vuejs.org/v2/guide/events.html#Event-Modifiers

The issue list of this repo is exclusively for bug reports and feature requests. For general questions, please join the Discord chat room. You can also check reddit or stackoverflow.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Prevent event bubbling in Vue - Stack Overflow
stop will stop the event propagation. In my case better solution was to use e.target != this.$el mounted() { window.addEventListener('click ...
Read more >
How to Stop Propagation of an Event in JS - JavaScript Tutorial
This tutorial shows you how to stop the propagation of an event in both capturing and bubbling phases using the Event.stopPropagation() method.
Read more >
How to correctly use preventDefault(), stopPropagation(), or ...
Stopping any event propagation — stopping the click event from bubbling up the DOM. If we refactor our code to jQuery, we can...
Read more >
How to stop propagation of an event in JavaScript
Learn how to stop the propagation of an event in both capturing and bubbling phases using the Event.stopPropagation() method in JavaScript.
Read more >
The Dangers of Stopping Event Propagation - CSS-Tricks
If you searched online to figure out the best way to do this, chances are you came across this Stack Overflow question: How...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found