DEV Community

Margaret W.N
Margaret W.N

Posted on

Day 86: Custom events in Vue

A custom event allows the parent component to listen to the events fired by child components. Data can be passed from a child to parent components as a payload of a custom event. $emit() is used to pass a custom event in vue. It take two parameters, the event name in kebab case and the payload(the data you want to pass).

And that is day 86 in a paragraph.

Top comments (0)