How get-advantage/advantage works
Main Components
a) Core Components:
• Advantage Wrapper (Central Component)
• Format Engine
• Messaging System
• UI Layer
• Publisher Integration
• Creative Integration
b) Format Types:
• TopScroll
• MidScroll
• WelcomePage
Component Relationships
Top Layer: Integration Points
Middle Layer: Core Framework
Bottom Layer: Format Implementation
Specific Implementation Details
a) Publisher Side:
• Integration point with website
• Configuration options
• Message handling system
b) Creative Side:
• Format rendering system
• UI components
• Message handling
c) Core Framework:
• Wrapper implementation
• Format management
• Security layer
• Messaging bus
Key Architectural Patterns to Highlight
• Message-based communication system (evident from messaging directory)
• Plugin-based format system (shown in formats directory)
• Separation of concerns between UI and logic
• Type-safe implementation (TypeScript usage)
Technical Stack Elements
• TypeScript as primary language
• Vite for building
• Cypress for testing
• CSS modules for styling
┌─────────────────────────────────────────┐
• Publisher Website │
• ┬───────────────────────┘
┌─────────────────▼───────────────────────┐
• Advantage Wrapper Layer │
• ┬───────────────────────┤
• Message Bus │ Security Layer │
• ┼───────────────────────┘
┌─────────────────▼───────────────────────┐
• Format Engine │
• ┬───────────┬─────────────────┤
• TopScroll │ MidScroll │ WelcomePage │
• ┴───────────┴─────────────────┘