Subscribe on changes!

@click.away event modifier

avatar
Aug 29th 2020

What problem does this feature solve?

Hi, recently I've had a ton of problems with making some dropdown component in Vue2. Then I've looked on Alpine.js and saw probably best feature I've seen this year ...

@click.away="doStuff"

This is exactly the kind of neat feature Vue 3 needs. It's simple and effective.

What does the proposed API look like?

<dropdown-body @click.away="isOpen = false">
...
</dropdown-body>