diff --git a/src/main.js b/src/main.js index 2318dbf..8b1243c 100644 --- a/src/main.js +++ b/src/main.js @@ -5,21 +5,20 @@ import { loadPostwall } from './components/postwall.js'; import { checkConsent, setUserConsent, showConsentPopup } from './utils/consent-utils.js'; document.addEventListener('DOMContentLoaded', async function () { - // Überprüfe Consent, bevor Inhalte geladen werden + // Starte sofort den Seitenaufbau + initializeApp(); + + // Überprüfe parallel den Consent-Status const consent = checkConsent(); if (!consent) { showConsentPopup( () => { setUserConsent(true); - initializeApp(); }, () => { setUserConsent(false); - initializeApp(); } ); - } else { - initializeApp(); } });