How danskernesdigitalebibliotek/dpl-go works
Main System Components
a. Frontend Layer:
• Next.js App Router (app/*)
• Client-side Components (components/*)
• State Management (store/*)
• UI Component Library (shadcn/ui integration)
b. API/Integration Layer:
• GraphQL Services (lib/graphql/*)
• REST Services (lib/rest/*)
• Authentication Services (app/auth/*)
c. External Services:
• Drupal CMS
• Cover Service API
• Publizon API
• UniLogin Service
Component Relationships
a. Client-Side Flow:
User Interface → Next.js App Router → React Query → API Layer → External Services
b. Authentication Flow:
User → Auth Routes → UniLogin Client → Session Management → Protected Routes
c. Data Flow:
GraphQL/REST Clients → External Services → Data Fetchers → React Components
Specific Implementation Details
Technical elements:
a. State Management:
• XState Machines (lib/machines/*)
• React Query for server state
• Local stores for UI state
b. Component Architecture:
• Global Components
• Page Layouts
• Shared Components
• Shadcn/UI Components
Technical Stack Indicators
• Next.js
• React
• TypeScript
• Tailwind CSS
• GraphQL
• REST APIs
Development Environment
A separate section for:
• Storybook integration
• Testing infrastructure (Cypress, Vitest)
• Quality assurance workflows
Deployment Flow
A deployment section showing:
• GitHub workflows
• Environment configurations
• Lagoon deployment process
The modular architecture with clear separation between
• UI components
• Business logic
• Data fetching
• External service integration
The central role of Next.js App Router in handling
• Routing
• Server-side rendering
• API routes
The integration points with external services
• Drupal CMS for content
• Cover Service for images
• Publizon for digital publications
• UniLogin for authentication
The robust development infrastructure
• Component development (Storybook)
• Testing (Cypress, Vitest)
• Quality assurance (GitHub workflows)