npm run serve:ssr funktioniert und Hamburger Menu bug fix

This commit is contained in:
2026-01-06 22:36:14 +01:00
parent 43027a54f7
commit 4f8fd77f7d
21 changed files with 371 additions and 111 deletions

View File

@@ -1,10 +1,20 @@
// IMPORTANT: DOM polyfill must be imported FIRST, before any browser-dependent libraries
import './ssr-dom-polyfill';
import { bootstrapApplication } from '@angular/platform-browser';
import { bootstrapApplication, BootstrapContext } from '@angular/platform-browser';
import { AppComponent } from './app/app.component';
import { config } from './app/app.config.server';
const bootstrap = () => bootstrapApplication(AppComponent, config);
const bootstrap = (context: BootstrapContext) => {
console.log('[SSR] Bootstrap function called');
const appRef = bootstrapApplication(AppComponent, config, context);
appRef.then(() => {
console.log('[SSR] Application bootstrapped successfully');
}).catch((err) => {
console.error('[SSR] Bootstrap error:', err);
console.error('[SSR] Error stack:', err.stack);
});
return appRef;
};
export default bootstrap;