2022-09-14 07:17:24 -04:00
|
|
|
import "../scss/style.scss";
|
2022-09-10 14:13:49 -04:00
|
|
|
import Alpine from "alpinejs";
|
2022-09-15 08:10:51 -04:00
|
|
|
import globalStore from "./store";
|
2022-09-15 07:50:41 -04:00
|
|
|
import navbar from "./navbar";
|
2022-09-15 08:10:51 -04:00
|
|
|
import cardsInputForm from "./cardsInputForm";
|
|
|
|
import playingCardsPreview from "./playingCardsPreview";
|
|
|
|
import gameSolving from "./gameSolving";
|
2022-09-12 20:51:12 -04:00
|
|
|
|
|
|
|
// Keep some constants in global store for components
|
2022-09-15 08:10:51 -04:00
|
|
|
Alpine.store("global", globalStore);
|
2022-09-12 20:51:12 -04:00
|
|
|
|
2022-09-14 09:54:03 -04:00
|
|
|
// navbar logic
|
2022-09-15 07:50:41 -04:00
|
|
|
Alpine.data("navbar", () => navbar);
|
2022-09-14 09:54:03 -04:00
|
|
|
|
2022-09-13 20:05:14 -04:00
|
|
|
// input component logic
|
2022-09-15 08:10:51 -04:00
|
|
|
Alpine.data("cardsInputForm", () => cardsInputForm);
|
2022-09-10 14:13:49 -04:00
|
|
|
|
2022-09-15 08:10:51 -04:00
|
|
|
// card preview component logic
|
|
|
|
Alpine.data("playingCardsPreview", () => playingCardsPreview);
|
2022-09-13 20:05:14 -04:00
|
|
|
|
|
|
|
// game solving component logic
|
2022-09-15 08:10:51 -04:00
|
|
|
Alpine.data("gameSolving", () => gameSolving);
|
2022-09-13 20:05:14 -04:00
|
|
|
|
2022-09-10 14:13:49 -04:00
|
|
|
window.Alpine = Alpine;
|
|
|
|
|
|
|
|
Alpine.start();
|