fix the context.emit functions
This commit is contained in:
parent
3065481a78
commit
3d51a62a14
|
@ -13,9 +13,9 @@
|
|||
export default {
|
||||
props: ['searchTerm'],
|
||||
emits: ['search'],
|
||||
setup(_, { emit }) {
|
||||
setup(_, context) {
|
||||
function search(event) {
|
||||
emit('search', event.target.value);
|
||||
context.emit('search', event.target.value);
|
||||
}
|
||||
return {
|
||||
search
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
export default {
|
||||
props: ['id', 'userName'],
|
||||
emits: ['list-projects'],
|
||||
setup(props, { emit }) {
|
||||
setup(props, context) {
|
||||
function viewProjects() {
|
||||
emit('list-projects', props.id);
|
||||
context.emit('list-projects', props.id);
|
||||
}
|
||||
return {
|
||||
viewProjects
|
||||
|
|
Reference in New Issue