11 lines
354 B
JavaScript
11 lines
354 B
JavaScript
import m from "mithril";
|
|
import { createChatApp } from "./components/ChatApp";
|
|
import { createWebSocket } from "./websocket";
|
|
import { Sessions } from "./session";
|
|
|
|
// open the WS to the server
|
|
const ws = createWebSocket();
|
|
const session = new Sessions();
|
|
const ChatApp = createChatApp({ ws, session });
|
|
m.mount(document.getElementById("app"), ChatApp);
|