init view
This commit is contained in:
parent
f66b3883c1
commit
336257d1d0
@ -11,6 +11,7 @@ import AbstractRedirectView from "./views/AbstractRedirectView.js";
|
|||||||
import MeView from "./views/MeView.js";
|
import MeView from "./views/MeView.js";
|
||||||
import ProfilePageView from "./views/profiles/ProfilePageView.js";
|
import ProfilePageView from "./views/profiles/ProfilePageView.js";
|
||||||
import ProfilesView from "./views/profiles/ProfilesView.js";
|
import ProfilesView from "./views/profiles/ProfilesView.js";
|
||||||
|
import MatchMakingView from "./views/MatchMakingView.js";
|
||||||
|
|
||||||
let client = new Client(location.protocol + "//" + location.host)
|
let client = new Client(location.protocol + "//" + location.host)
|
||||||
|
|
||||||
@ -44,6 +45,7 @@ const router = async (uri = "") => {
|
|||||||
{ path: "/chat", view: Chat },
|
{ path: "/chat", view: Chat },
|
||||||
{ path: "/home", view: HomeView },
|
{ path: "/home", view: HomeView },
|
||||||
{ path: "/me", view: MeView },
|
{ path: "/me", view: MeView },
|
||||||
|
{ path: "/matchmaking", view: MatchMakingView },
|
||||||
];
|
];
|
||||||
|
|
||||||
// Test each route for potential match
|
// Test each route for potential match
|
||||||
|
@ -9,6 +9,7 @@ export default class extends AbstractAuthentificateView {
|
|||||||
async getHtml() {
|
async getHtml() {
|
||||||
return `
|
return `
|
||||||
<h1>HOME</h1>
|
<h1>HOME</h1>
|
||||||
|
<a href="/matchmaking" class="nav__link" data-link>Play a game</a>
|
||||||
<a href="/me" class="nav__link" data-link>Me</a>
|
<a href="/me" class="nav__link" data-link>Me</a>
|
||||||
<a href="/logout" class="nav__link" data-link>Logout</a>
|
<a href="/logout" class="nav__link" data-link>Logout</a>
|
||||||
`;
|
`;
|
||||||
|
13
frontend/static/js/views/MatchMakingView.js
Normal file
13
frontend/static/js/views/MatchMakingView.js
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
import AbstractView from "./AbstractView.js";
|
||||||
|
|
||||||
|
export default class extends AbstractView {
|
||||||
|
constructor(params) {
|
||||||
|
super(params, "Dashboard");
|
||||||
|
}
|
||||||
|
|
||||||
|
async getHtml() {
|
||||||
|
return `
|
||||||
|
<h1>finding<h1>
|
||||||
|
`;
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user