Refactor emit field change into a utility function
This commit is contained in:
6
js/lib/emitters.js
Normal file
6
js/lib/emitters.js
Normal file
@@ -0,0 +1,6 @@
|
||||
export const emitFieldChange = (el, data) => {
|
||||
el.$root.$emit('field-change', {
|
||||
...data,
|
||||
parent_uid: el.$parent && el.$parent._uid,
|
||||
})
|
||||
}
|
Reference in New Issue
Block a user