zeed-dynamic-table
Version:
A flexible and dynamic table component for React and Next.js applications without Tailwind dependencies
37 lines (36 loc) • 1.11 kB
TypeScript
/**
* Get React version - works with React 18, 19 and future versions
*/
export declare function getReactVersion(): string | null;
/**
* Check if the app is using React 18 or newer
*/
export declare function isReact18OrNewer(): boolean;
/**
* Check if the app is running in Next.js
*/
export declare function isNextJs(): boolean;
/**
* Get Next.js version if being used
*/
export declare function getNextJsVersion(): string | null;
/**
* Check if the app is using Next.js 13 or newer
*/
export declare function isNextJs13OrNewer(): boolean;
/**
* Check if we need to use new React 18+ specific APIs
*/
export declare function shouldUseReact18APIs(): boolean;
/**
* Check if we need to use concurrent features
*/
export declare function supportsConcurrentFeatures(): boolean;
/**
* Get appropriate use transition based on React version
*/
export declare function getUseTransition(): any;
/**
* Helper for safely using features that may not be available in all React versions
*/
export declare function safelyRunWithFallback<T>(modernImplementation: () => T, fallbackImplementation: () => T): T;