@wizecorp/stratusjs
Version:
Stratus React Framework
32 lines • 1.15 kB
TypeScript
import React from 'react';
import { ServiceContainer } from '../services/ServiceContainer';
import type { RouteDefinition } from './types';
import type { StratusConfig } from '../config';
interface HybridRouterProps {
config?: Partial<StratusConfig>;
fallback?: React.ReactNode;
errorBoundary?: React.ComponentType<{
error: Error;
retry: () => void;
}>;
routes?: RouteDefinition[];
serviceContainer?: ServiceContainer;
}
/**
* Hybrid router that supports both client-side and server-side rendering
*/
export declare const HybridRouter: React.FC<HybridRouterProps>;
/**
* Client-side hydration function
*/
export declare const hydrateApp: (element: React.ReactElement, container: HTMLElement, callback?: () => void) => void;
/**
* Helper to create a Stratus app with SSR support
*/
export declare const createStratusApp: (props: HybridRouterProps) => import("react/jsx-runtime").JSX.Element;
/**
* Mount the app to DOM (client-side)
*/
export declare const mountApp: (props: HybridRouterProps, containerId?: string, callback?: () => void) => void;
export {};
//# sourceMappingURL=HybridRouter.d.ts.map