mirror of
https://github.com/stackblitz-labs/bolt.diy
synced 2025-06-26 18:26:38 +00:00
31 lines
779 B
TypeScript
31 lines
779 B
TypeScript
/*
|
|
* @ts-nocheck
|
|
* Preventing TS checks with files presented in the video for a better presentation.
|
|
*/
|
|
import { useChatHistory } from '~/lib/persistence';
|
|
import { renderLogger } from '~/utils/logger';
|
|
import ChatImplementer from './components/ChatImplementer/ChatImplementer';
|
|
import flushSimulationData from './functions/flushSimulation';
|
|
|
|
setInterval(async () => {
|
|
flushSimulationData();
|
|
}, 1000);
|
|
|
|
export function Chat() {
|
|
renderLogger.trace('Chat');
|
|
|
|
const { ready, initialMessages, resumeChat, storeMessageHistory } = useChatHistory();
|
|
|
|
return (
|
|
<>
|
|
{ready && (
|
|
<ChatImplementer
|
|
initialMessages={initialMessages}
|
|
resumeChat={resumeChat}
|
|
storeMessageHistory={storeMessageHistory}
|
|
/>
|
|
)}
|
|
</>
|
|
);
|
|
}
|