Skip to content
CAI
Software that uses CAICheck a score

Melzar/clean-architecture-nextjs-react-boilerplate

55.8

Adequate · 21 September 2026

3.6k

lines of production code

TypeScript

primary language

4

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a Next.js-based administrative dashboard application designed for managing clients and packages. It implements a clean architecture with a distinct domain, data, and presentation layers, utilizing dependency injection and REST clients to fetch and display data. The application provides authentication, role-based access control, and UI components for viewing client details, package statuses, and dashboard widgets.

Features

Added Packages admin screen with status icons and layout

The admin interface now includes a dedicated Packages screen, featuring a header with widgets and a list of latest packages. The change introduces a data hook (usePackagesData) to fetch package information, a dictionary for text labels, and partials that map package statuses (e.g., processing, shipped, in\_transit) to specific icons and CSS classes. The view component assembles these elements, providing a structured layout for managing package information in the admin panel.

src/ui/Packages/Admin · medium confidence

Added Product model definition

A new TypeScript type for Product has been introduced in the domain models, defining the structure with an id and productName fields.

src/domain/Packages/models · high confidence

Added login page and layout components

Introduced the initial structure for the login feature by adding a new layout component (src/app/login/layout.tsx) and a page component (src/app/login/page.tsx). The page component renders the LoginView from the 'ui' package, establishing the entry point for the login flow.

src/app/login · high confidence

Added new admin pages for clients, dashboard, and packages

New page components have been introduced for the admin section, including pages for clients (listing and individual view), dashboard, and packages. Each page renders a corresponding view component (e.g., ClientView, ClientsView, DashboardView, PackagesView) within the admin layout, enabling navigation and display of these specific administrative features.

src/app/admin · high confidence

Added package fetching capabilities and supporting types

Introduced new files to support fetching package data, including the \PackagesEndpoints\ and \PackagesInputs\ constants, \FetchClientPackagesRequest\ and \FetchClientRequest\ types, \IPackagesRepository\ interface, \GetPackageRepositoryRequest\ type, \FetchPackageUseCase\ and \FetchPackagesUseCase\ implementations, \FetchPackageRequest\ type, \FetchPackagePresenterRequest\ type, and the \Package\ model. These additions enable the application to retrieve package information from the API and process it through the domain layer.

(repo-wide) · high confidence

Added project configuration and tooling setup

The project now includes essential configuration files to support development and build processes. This includes environment variable templates (.env.development, .docker.env.development) for API and authentication settings, a Dockerfile defining build stages for the application, mock server, and Storybook, and a .nvmrc file to enforce Node.js version 18.17.1. Additionally, the repository now features a comprehensive ESLint configuration (.eslintrc.json) that enforces coding standards, import ordering, and layer restrictions for the clean architecture, alongside Prettier and Stylelint configurations for consistent code formatting and style checking.

(repo-wide) · high confidence

Implemented data layer with REST client, repositories, and dependency injection

Added a new data layer that defines REST client configuration, API endpoint constants, and repository implementations for authentication, clients, and packages. This includes type definitions, mappers for domain models, and InversifyJS-based dependency injection modules that wire repositories to use cases and presenters, enabling the application to fetch and transform data from the backend API.

src/data · high confidence

Initial Storybook configuration for the project

Added Storybook configuration files (main.ts, preview.tsx, storybook.scss) to enable a component-driven development environment. This includes setting up the Next.js framework integration, enabling RSC support, configuring essential addons (links, essentials, onboarding, interactions, styling), and applying global styles to the Storybook preview.

.storybook · high confidence

Initial app structure and layout setup

The application now includes a root layout that provides global styling via Tailwind CSS and CSS variables, along with an AuthenticationProvider to manage authentication state across the app. A dashboard route has been added, featuring a MemberLayout wrapper and a DashboardView component. The home page displays a simple 'Home' text, and global styles define light and dark mode color schemes.

src/app · high confidence

Initial clean architecture implementation for authentication, clients, and packages

The application now includes a complete clean architecture structure for handling authentication, client data, and package data. This introduces domain models and repository interfaces for user authentication and client management, alongside use cases for fetching clients and their associated packages. The presentation layer provides corresponding presenters and mappers to bridge the domain logic with the view layer, enabling the UI to authenticate users and retrieve client and package information.

src/domain · high confidence

Introduce authentication, client, and dashboard UI components

Added a new login page with a form for email and password, protected by a Next.js middleware that enforces authentication and redirects users to the appropriate dashboard based on their role (admin or member). The admin dashboard now displays widgets summarizing package statuses (new, in transit, delivered, attention needed) and recent packages. A new client management section allows admins to view a list of clients and drill down into individual client details, including their associated packages and widgets. Common UI components such as buttons, layout containers, and font definitions have also been introduced.

src/ui · high confidence

Behavioural changes

Added Next.js API route for authentication and a custom 403 Forbidden page

Users can now authenticate via the new API route at /api/auth/\[...nextauth\], which integrates with the existing AuthenticationOptions configuration. Additionally, a dedicated 403 Forbidden page has been added to handle unauthorized access scenarios, displaying a 'FORBIDDEN 403' message.

src/app/api, src/app/forbidden · medium confidence

Added pre-commit hook for linting staged files

A new pre-commit hook has been added to the .husky directory, which automatically runs 'npx lint-staged' on each commit. This ensures that staged files are linted before being committed, helping to maintain code quality and consistency.

.husky · high confidence

Test coverage

Added end-to-end tests for the Admin dashboard, clients, and packages screens

New end-to-end test files have been added to the \e2e\ directory, establishing automated verification for the Admin user interface. This includes Cucumber feature files and Page Object Model classes for the Admin Dashboard, Clients list, Client Details, and Packages screens. The tests validate that an admin user can log in, navigate to these screens, and verify the presence of specific UI components such as package status widgets and client lists.

e2e · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

Score

  • CAI 55 → 56 (+0.8)
  • Rubric changed (rubric-2026.08.19 → rubric-2026.09.15) — scores are not directly comparable.

Lenses

  • Code Health 86 → 91 (+5.0)
  • Architecture 91 → 84 (-7.0)
  • Maturity 75 → 79 (+3.7)
  • Readiness 31 → 35 (+4.3)
  • Security 79 → 75 (-3.7)
  • Accessibility 71 → 68 (-2.5)

Resolved (57)

  • Coverage not included — suite not readable by the collector
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical vulnerability: [GHSA redacted] (yarn.lock)
  • Critical vulnerability: [GHSA redacted] (yarn.lock)
  • Dependency hygiene not measured — dependency manifest found but not parsed for hygiene
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • …and 37 more

New (94)

  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical CVE: [GHSA redacted] (yarn.lock)
  • Critical vulnerability: [GHSA redacted] (yarn.lock)
  • Critical vulnerability: [GHSA redacted] (yarn.lock)
  • Documentation: no usage examples (README.md)
  • End-of-life runtime: Node.js 18
  • FunctionTooLong: dashboard.view.DashboardView (src/ui/Dashboard/Admin/dashboard.view.tsx)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • High CVE: [GHSA redacted] (yarn.lock)
  • …and 74 more

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

Melzar/clean-architecture-nextjs-react-boilerplate was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 21 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit 64e9770a3d84606ca9fdef1223d99695f07a9aed — the exact code this score is about.
  • Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-b84573e22831.