18 lines
496 B
TypeScript
18 lines
496 B
TypeScript
import React from 'react';
|
|
import { io } from "socket.io-client";
|
|
import LandingPage from './pages/landing/LandingPage';
|
|
|
|
function App() {
|
|
const socket = io("http://localhost:3010");
|
|
const emitData = () => console.log(socket.emit("example-request", "custom-request"));
|
|
socket.on("example-response", (data) => console.log(`Received response in front end with data: ${data}`));
|
|
|
|
return (
|
|
<div className="App">
|
|
<LandingPage socket={socket}/>
|
|
</div>
|
|
);
|
|
}
|
|
|
|
export default App;
|