-1👍
Here is the example code we can follow.
emitEvent() {
this.$emit("myEvent", "name", "password")
}
Here is the test case
describe("Emitter", () => {
it("emits an event with two arguments", () => {
const wrapper = shallowMount(Emitter)
wrapper.vm.emitEvent()
console.log(wrapper.emitted())
})
})
- [Vuejs]-Vuejs 2 removing from array (splice) not animating with transition
- [Vuejs]-Not Found error importing an image to Trois js texture
Source:stackexchange.com