Hi there😊
I noticed this great project for building a simple and strong chat web application, but during the usage I found some issues which is mentioned in #3 . I've optimized the ts definition by using setup lang='ts' sugar syntax and defineProps api. Except the origin five files in vue version, I add a type file named message to define the single message in chatdata. Next I wish the definition of message may have more detail like message<T extends 'chatbot' | 'person'> which is I'm using outside of the component now. By the way, I've fixed the scroll behavior to adapt my stream response from the server, now it can always scroll to the right position.
However, though I optimized these problems, I won't pull a request directly because this project is a little complicated for me especially the structure for build three version at one time. So I publish a new npm package https://www.npmjs.com/package/@heyzayn/components and the corresponding source code at https://github.com/DSYZayn/components/tree/main/packages/ChatUI
Wish you can benefit from it.
Hi there😊
I noticed this great project for building a simple and strong chat web application, but during the usage I found some issues which is mentioned in #3 . I've optimized the ts definition by using
setup lang='ts'sugar syntax anddefinePropsapi. Except the origin five files in vue version, I add a type file namedmessageto define the single message in chatdata. Next I wish the definition of message may have more detail like message<T extends 'chatbot' | 'person'> which is I'm using outside of the component now. By the way, I've fixed the scroll behavior to adapt my stream response from the server, now it can always scroll to the right position.However, though I optimized these problems, I won't pull a request directly because this project is a little complicated for me especially the structure for build three version at one time. So I publish a new npm package https://www.npmjs.com/package/@heyzayn/components and the corresponding source code at https://github.com/DSYZayn/components/tree/main/packages/ChatUI
Wish you can benefit from it.