Fullmetal Chat Example
git clone https://github.com/m0dE/fullmetal-chat-example.gitnpm install// .env FULLMETAL_API_KEY=YOUR_API_KEYnpm run dev:frontendnpm run dev:backendimport { defineConfig } from 'vite'; import react from '@vitejs/plugin-react-swc'; // https://vitejs.dev/config/ export default defineConfig({ plugins: [react()], server: { port: '443', https: { key: 'key.pem', cert: 'cert.pem', }, proxy: { '/socket.io': { target: 'YOUR_WEBSOCKET_LINK', // This is chat backend websocket address. As we are using websocket connection between chat-frontend and chat-backend, we need to configure this proxy in order to make it work ws: true, }, }, }, });npm run dev:secure:backend
Last updated