Rocky_Mountain_Vending/.pnpm-store/v10/files/a0/8179b69c67b431282ceaacd30814b8813eb36e8e31a3a68f48b5fa10ff8586954d8de84f24c268d07494a66a0127439d115d4a97af93a9d6128a2e8052d375
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

14 lines
526 B
Text

import * as React from 'react';
import { useSidecar } from './hook';
// eslint-disable-next-line @typescript-eslint/ban-types
export function sidecar(importer, errorComponent) {
const ErrorCase = () => errorComponent;
return function Sidecar(props) {
const [Car, error] = useSidecar(importer, props.sideCar);
if (error && errorComponent) {
return ErrorCase;
}
// @ts-expect-error type shenanigans
return Car ? React.createElement(Car, { ...props }) : null;
};
}