This is the same triggering event as vue2. X, except that the setup function takes an object or context object as its second argument

So inside the setup function is still:

This.$emit(' event ', parameter) context.emit(' event ', parameter) // Or use the object as shown in the image to emit(' event ', parameter).Copy the code