We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
使用ProChatChatReference中的pushChat实际可以添加extra属性用于复杂业务,但参数类型被限制为了只有id、content、role属性的object
更正为ChatMessage类型校验
export default Chat(props => { const chatRef = useRef<ProChatInstance>(); useEffect(()=> { chatRef.current.pushChat({ id: randomString, content: "need change typescript", role: "user", // 这里会报类型错误缺少extra属性 extra: { something: "useful" } }) }, []) return ( <ProChat ref={chatRef} .... /> ) })
The text was updated successfully, but these errors were encountered:
No branches or pull requests
🐛 bug 描述
使用ProChatChatReference中的pushChat实际可以添加extra属性用于复杂业务,但参数类型被限制为了只有id、content、role属性的object
🏞 期望结果
更正为ChatMessage类型校验
💻 复现代码
© 版本信息
The text was updated successfully, but these errors were encountered: