Dual-Brand Architecture

Configure a single codebase to support multiple brands via runtime configuration.

Updated Dec 23, 2025
One-click install
npx skills add https://github.com/tachfineamnay/LumiraV2 --skill dual-brand-architecture
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: Dual-Brand Architecture
Source: https://github.com/tachfineamnay/LumiraV2/tree/main/skills/06-dual-brand
Command: npx skills add https://github.com/tachfineamnay/LumiraV2 --skill dual-brand-architecture

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

In a single codebase, this skill enables two distinct brands to share UI and logic while remaining independently configurable and isolated.

Core Features & Use Cases

  • Brand-driven theming: Dynamically apply brand-specific styles based on subdomain or header.
  • Config-driven content: Route, copy, and features switch automatically via per-brand configuration.
  • Use Case: A SaaS platform serving patients and clinicians can deploy SocioPulse and MedicoPulse from one codebase without duplicating components.

Quick Start

  1. Review lib/brand.config.ts to understand the BRANDS map and how domains map to features.
  2. Ensure middleware detects the brand and exposes it through a context provider for UI components.
  3. Introduce brand-specific content via the configuration layer without hardcoding brand names.

Frequently Asked Questions about Dual-Brand Architecture

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I support multiple brands from a single codebase without hardcoding brand logic?

Support multiple brands from a single codebase by using runtime configuration to drive theming, routing, and features. This approach ensures zero hardcode brand logic, allowing dynamic switching based on domains or headers.

How does dynamic theming work for multi-brand SaaS applications?

Dynamic theming for multi-brand applications works through middleware that detects the brand via subdomain or header. It then applies brand-specific styles and content automatically via a context provider and configuration layer.

Can I use subdomain routing to switch feature flags and UI components per brand?

Yes, you can use subdomain routing to switch feature flags and UI components per brand. A brand configuration map links domains to specific features, allowing route and feature switching automatically through per-brand configuration.

What is the best way to manage configuration-driven content for different domains?

The best way to manage configuration-driven content for different domains is using a centralized brand configuration map. This map routes copy, features, and styles dynamically based on the detected domain, avoiding component duplication.

Does multi-brand theming require duplicating components for each brand?

Multi-brand theming does not require duplicating components for each brand. A single codebase shares UI and logic while remaining independently configurable and isolated through a configuration layer and context provider.