Template
feat : guess word
This commit is contained in:
@@ -1,10 +1,17 @@
|
||||
import { useGameStore } from "~/store/game.store";
|
||||
|
||||
const validPaths = ["/", "/rules", "/test", "/words"];
|
||||
|
||||
export default defineNuxtRouteMiddleware(async (to, from) => {
|
||||
const config = useRuntimeConfig();
|
||||
|
||||
if (to.path.startsWith("/game/")) {
|
||||
const gameId = Number(to.params.id);
|
||||
const gameStore = useGameStore();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (to.path == "/login") {
|
||||
const code = to.query.code;
|
||||
if (!code) {
|
||||
|
||||
Reference in New Issue
Block a user