Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

我怎么可以向message里添加一些额外的属性呢 #696

Open
EVA-Zero812 opened this issue Apr 18, 2021 · 0 comments
Open

我怎么可以向message里添加一些额外的属性呢 #696

EVA-Zero812 opened this issue Apr 18, 2021 · 0 comments

Comments

@EVA-Zero812
Copy link

比如我在测试demo获取历史消息的函数里写了个message.data = { id : '1', name : 'xxx' },但是在另一个函数,比如单击消息的函数里打印出来的message还是只有那几个默认的值
getHistoryMessage(){
message.data = { id : '1', name : 'xxx' }
messages.push(message);
AuroraIController.appendMessages(messages);
}
onMsgClick(message){
console.log(message.data) // undefined ,message里只有初始的那几个值
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant