OWOX Data Marts Monorepo Structure
This document describes the structure of the OWOX Data Marts monorepo, which is organized to separate deployable applications from shared packages.
Overview
Section titled βOverviewβThe monorepo is divided into two main sections:
apps/
- Contains deployable applications and runtimespackages/
- Contains shared libraries and configurations
Directory Structure
Section titled βDirectory Structureβowox-data-marts/βββ apps/ # Deployable applicationsβ βββ web/ # Frontend web applicationβ β βββ src/ # Source codeβ β βββ dist/ # Build artifactsβ ββ βββ backend/ # Backend API and platform runtimeβ β βββ src/ # Source codeβ ββ βββ cli/ # Command-line interface toolβ βββ src/ # Source codeββββ packages/ # Shared libraries and configurationsβ βββ ui/ # Shared UI components and design systemβ β βββ src/ # Source codeβ ββ βββ connectors/ # Data connectors and API integrationsβ β βββ src/ # Source codeβ ββ βββ connector-runner/ # Core connector execution logicβ β βββ src/ # Source codeβ ββ βββ eslint-config/ # Shared ESLint configurationsβ ββ βββ prettier-config/ # Shared Prettier configurationsβ ββ βββ typescript-config/ # Shared TypeScript configurationsββββ tools/ # Additinal scripts for projectβββ docs/ # Project documentation
Applications (apps/
)
Section titled βApplications (apps/)βWeb Application (apps/web/
)
Section titled βWeb Application (apps/web/)β- React-based frontend application
- Serves the main user interface
- Consumes shared UI components from
packages/ui
- Build artifacts are served by the backend
Backend (apps/backend/
)
Section titled βBackend (apps/backend/)β- NestJS-based backend API
- Serves the web applicationβs build artifacts
- Implements platform runtime
- Uses shared packages for data connectors execution
CLI Tool (apps/owox/
)
Section titled βCLI Tool (apps/owox/)β- Command-line interface for platform management
- Published as global npm package (
owox
) - Reuses backend logic and connectors
- Designed for global installation:
npm i -g owox
Shared Packages (packages/
)
Section titled βShared Packages (packages/)βUI Package (packages/ui/
)
Section titled βUI Package (packages/ui/)β- Shared React components
- Implements shadcn/ui-based design system
- Tailwind CSS styling
- Used by the web application and other frontends outside of this monorepo
Connectors (packages/connectors/
)
Section titled βConnectors (packages/connectors/)β- Data Source integrations
- Shared across backend and CLI
Connector runner (packages/connector-runner/
)
Section titled βConnector runner (packages/connector-runner/)β- Core logic for connector execution
- Used by backend and CLI
Development Workflow
Section titled βDevelopment Workflowβ- Each app and package has its own
package.json
- Dependencies between packages are managed using workspace references
- Shared configurations (linting, TypeScript) are maintained in respective packages
- Build artifacts are generated in respective
dist/
directories
Package Management
Section titled βPackage Managementβ- Root
package.json
defines workspaces for bothapps/*
andpackages/*
- Each package can be developed and tested independently
- Dependencies between packages use
workspace:*
syntax - Shared packages are not published to npm but used internally
Best Practices
Section titled βBest Practicesβ- Keep shared code in appropriate packages
- Maintain clear boundaries between apps and packages
- Use TypeScript for type safety across the monorepo
- Follow consistent coding standards using shared linter config
- Document public APIs and interfaces