Full Code of Blazity/next-enterprise for AI

main e5e9735e943c cached
41 files
56.6 KB
18.8k tokens
16 symbols
1 requests
Download .txt
Repository: Blazity/next-enterprise
Branch: main
Commit: e5e9735e943c
Files: 41
Total size: 56.6 KB

Directory structure:
gitextract_1vk2cap0/

├── .all-contributorsrc
├── .github/
│   ├── nodejs.version
│   └── workflows/
│       ├── check.yml
│       ├── nextjs_bundle_analysis.yml
│       └── playwright.yml
├── .gitignore
├── .pre-commit-config.yaml
├── .prettierignore
├── .releaserc
├── .storybook/
│   ├── main.ts
│   └── preview.ts
├── .vscode/
│   └── settings.json
├── LICENSE
├── README.md
├── app/
│   ├── api/
│   │   └── health/
│   │       └── route.ts
│   ├── layout.tsx
│   └── page.tsx
├── components/
│   ├── Button/
│   │   ├── Button.stories.tsx
│   │   ├── Button.test.tsx
│   │   └── Button.tsx
│   └── Tooltip/
│       └── Tooltip.tsx
├── e2e/
│   └── example.spec.ts
├── env.mjs
├── eslint.config.mjs
├── git-conventional-commits.yaml
├── instrumentation.ts
├── lp-items.tsx
├── next-env.d.ts
├── next.config.ts
├── package.json
├── playwright.config.ts
├── postcss.config.js
├── prettier.config.js
├── renovate.json
├── report-bundle-size.js
├── reset.d.ts
├── styles/
│   └── tailwind.css
├── tsconfig.json
├── vercel.json
├── vitest.config.ts
└── vitest.setup.ts

================================================
FILE CONTENTS
================================================

================================================
FILE: .all-contributorsrc
================================================
{
  "projectName": "next-enterprise",
  "projectOwner": "Blazity",
  "repoType": "github",
  "repoHost": "https://github.com",
  "files": [
    "README.md"
  ],
  "imageSize": 100,
  "commit": true,
  "commitConvention": "angular",
  "contributors": [
    {
      "login": "bmstefanski",
      "name": "Bart Stefanski",
      "avatar_url": "https://avatars.githubusercontent.com/u/28964599?v=4",
      "profile": "https://bstefanski.com/",
      "contributions": [
        "code"
      ]
    },
    {
      "login": "jjablonski-it",
      "name": "Jakub Jabłoński",
      "avatar_url": "https://avatars.githubusercontent.com/u/51968772?v=4",
      "profile": "https://github.com/jjablonski-it",
      "contributions": [
        "infra"
      ]
    },
    {
      "login": "neg4n",
      "name": "Igor Klepacki",
      "avatar_url": "https://avatars.githubusercontent.com/u/57688858?v=4",
      "profile": "https://neg4n.dev/",
      "contributions": [
        "doc"
      ]
    }
  ],
  "contributorsPerLine": 7,
  "linkToUsage": true,
  "commitType": "docs"
}


================================================
FILE: .github/nodejs.version
================================================
v24.3.0


================================================
FILE: .github/workflows/check.yml
================================================
name: Check

on:
  push:
    branches:
      - main
      - master
      - develop
  pull_request:
  workflow_dispatch:

jobs:
  check:
    name: Check
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - run: echo "node_version=$(cat .github/nodejs.version)" >> $GITHUB_ENV
      - name: "use node ${{ env.node_version }}"
        uses: actions/setup-node@v3
        with:
          node-version: "${{ env.node_version }}"

      - name: "Install pnpm & dependencies"
        uses: pnpm/action-setup@v4
        with:
          run_install: |
            - recursive: true
            - args: [--frozen-lockfile]

      - name: Lint check
        run: pnpm run lint
      - name: Format check
        run: pnpm run prettier
      - name: Unit & Integration tests
        run: pnpm run test
      - name: Smoke & Acceptance tests
        run: |
          pnpm run build-storybook --quiet
          pnpm playwright install
          pnpm dlx concurrently -k -s first -n "SB,TEST" -c "magenta,blue" \
            "pnpm dlx http-server storybook-static --port 6006 --silent" \
            "pnpm dlx wait-on tcp:127.0.0.1:6006 && pnpm run test-storybook"


================================================
FILE: .github/workflows/nextjs_bundle_analysis.yml
================================================
name: "Next.js Bundle Analysis"

on:
  push:
    branches:
      - main
      - develop
  pull_request:
    branches:
      - main
      - develop
  workflow_dispatch:

defaults:
  run:
    # change this if your nextjs app does not live at the root of the repo
    working-directory: ./

jobs:
  analyze:
    env:
      SKIP_ENV_VALIDATION: true
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - name: Set up node
        uses: actions/setup-node@v3
        with:
          node-version: "20.x"

      - name: "Install pnpm & dependencies"
        uses: pnpm/action-setup@v4
        with:
          run_install: |
            - recursive: true
            - args: [--frozen-lockfile]

      # - name: Install dependencies
      #   run: pnpm install --frozen-lockfile

      - name: Restore next build
        uses: actions/cache@v3
        id: restore-build-cache
        env:
          cache-name: cache-next-build
        with:
          path: .next/cache
          # change this if you prefer a more strict cache
          key: ${{ runner.os }}-build-${{ env.cache-name }}

      - name: Build next.js app
        env:
          SKIP_BUILD_PRODUCT_REDIRECTS: 1
        # change this if your site requires a custom build command
        run: pnpm build

      # Here's the first place where next-bundle-analysis' own script is used
      # This step pulls the raw bundle stats for the current bundle
      - name: Analyze bundle
        run: node report-bundle-size.js

      - name: Upload bundle
        uses: actions/upload-artifact@v4
        with:
          name: bundle
          path: .next/analyze/__bundle_analysis.json

      - name: Download base branch bundle stats
        uses: dawidd6/action-download-artifact@v8
        if: success() && github.event.number
        with:
          workflow: nextjs_bundle_analysis.yml
          branch: ${{ github.event.pull_request.base.ref }}
          path: .next/analyze/base

      # And here's the second place - this runs after we have both the current and
      # base branch bundle stats, and will compare them to determine what changed.
      # There are two configurable arguments that come from package.json:
      #
      # - budget: optional, set a budget (bytes) against which size changes are measured
      #           it's set to 350kb here by default, as informed by the following piece:
      #           https://infrequently.org/2021/03/the-performance-inequality-gap/
      #
      # - red-status-percentage: sets the percent size increase where you get a red
      #                          status indicator, defaults to 20%
      #
      # Either of these arguments can be changed or removed by editing the `nextBundleAnalysis`
      # entry in your package.json file.
      - name: Compare with base branch bundle
        if: success() && github.event.number
        run: ls -laR .next/analyze/base && npx -p nextjs-bundle-analysis compare

      - name: Get comment body
        id: get-comment-body
        if: success() && github.event.number
        uses: actions/github-script@v6
        with:
          result-encoding: string
          script: |
            const fs = require('fs')
            const comment = fs.readFileSync('.next/analyze/__bundle_analysis_comment.txt', 'utf8')
            core.setOutput('body', comment)

      - name: Find Comment
        uses: peter-evans/find-comment@v2
        if: success() && github.event.number
        id: fc
        with:
          issue-number: ${{ github.event.number }}
          body-includes: "<!-- __NEXTJS_BUNDLE -->"

      - name: Create Comment
        uses: peter-evans/create-or-update-comment@v3
        if: success() && github.event.number && steps.fc.outputs.comment-id == 0
        with:
          issue-number: ${{ github.event.number }}
          body: ${{ steps.get-comment-body.outputs.body }}

      - name: Update Comment
        uses: peter-evans/create-or-update-comment@v3
        if: success() && github.event.number && steps.fc.outputs.comment-id != 0
        with:
          issue-number: ${{ github.event.number }}
          body: ${{ steps.get-comment-body.outputs.body }}
          comment-id: ${{ steps.fc.outputs.comment-id }}
          edit-mode: replace


================================================
FILE: .github/workflows/playwright.yml
================================================
name: Playwright Tests
on:
  push:
    branches:
      - main
      - master
      - develop
  pull_request: null
  workflow_dispatch: null
jobs:
  test:
    timeout-minutes: 60
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - run: echo "node_version=$(cat .github/nodejs.version)" >> $GITHUB_ENV
      - name: "use node ${{ env.node_version }}"
        uses: actions/setup-node@v3
        with:
          node-version: "${{ env.node_version }}"

      - name: "Install pnpm & dependencies"
        uses: pnpm/action-setup@v4
        with:
          run_install: |
            - recursive: true
            - args: [--frozen-lockfile]

      - name: Install Playwright Browsers
        run: pnpm playwright install --with-deps

      - name: Run Playwright tests
        run: pnpm playwright test

      - uses: actions/upload-artifact@v4
        if: always()
        with:
          name: playwright-report
          path: playwright-report/
          retention-days: 30


================================================
FILE: .gitignore
================================================
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.

# dependencies
node_modules
.pnp
.pnp.js

# testing
coverage

# next.js
.next/
out/
build

# misc
.DS_Store
*.pem

# debug
npm-debug.log*
yarn-debug.log*
yarn-error.log*
.pnpm-debug.log*

# local env files
.env.local
.env.development.local
.env.test.local
.env.production.local
storybook-static/
/test-results/
/playwright-report/
/playwright/.cache/

/.npm-only-allow
.pnpm-store/

================================================
FILE: .pre-commit-config.yaml
================================================
repos:
  - repo: https://github.com/qoomon/git-conventional-commits
    rev: v2.6.3
    hooks:
      - id: conventional-commits


================================================
FILE: .prettierignore
================================================
.next
node_modules

================================================
FILE: .releaserc
================================================
{
  branches: ["main"],
  "plugins":
    [
      ["@semantic-release/npm", { "npmPublish": false }],
      "@semantic-release/release-notes-generator",
      "@semantic-release/github",
      "@semantic-release/commit-analyzer",
      "@semantic-release/git",
      "@semantic-release/changelog",
    ],
}


================================================
FILE: .storybook/main.ts
================================================
import type { StorybookConfig } from "@storybook/nextjs"
const config: StorybookConfig = {
  stories: ["../components/**/*.stories.mdx", "../components/**/*.stories.@(js|jsx|ts|tsx)"],
  addons: ["@storybook/addon-links", "@storybook/addon-essentials", "@storybook/addon-interactions"],
  framework: {
    name: "@storybook/nextjs",
    options: {},
  },
  docs: {
    autodocs: "tag",
  },
  typescript: {
    check: false,
    checkOptions: {},
    reactDocgen: false,
    reactDocgenTypescriptOptions: {
      shouldExtractLiteralValuesFromEnum: true,
      propFilter: (prop) => (prop.parent ? !/node_modules/.test(prop.parent.fileName) : true),
    },
  },
}
export default config


================================================
FILE: .storybook/preview.ts
================================================
import type { Preview } from "@storybook/react"

import "../styles/tailwind.css"

const preview: Preview = {
  parameters: {
    actions: { argTypesRegex: "^on[A-Z].*" },
    controls: {
      matchers: {
        color: /(background|color)$/i,
        date: /Date$/,
      },
    },
  },
}

export default preview


================================================
FILE: .vscode/settings.json
================================================
{
  "tailwindCSS.experimental.classRegex": [
    ["cva(?:<[^>]*>)?(([^)]*))", "[\"'`]([^\"'`]*).*?[\"'`]", "(?:twMerge|twJoin)\\(([^\\);]*)[\\);]"]
  ]
}


================================================
FILE: LICENSE
================================================
MIT License

Copyright (c) 2023 Blazity

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


================================================
FILE: README.md
================================================

# [Next.js Enterprise Boilerplate](https://blazity.com/open-source/nextjs-enterprise-boilerplate) 

A production-ready template for building enterprise applications with Next.js. This boilerplate provides a solid foundation with carefully selected technologies and ready-to-go infrastructure to help you develop high-quality applications efficiently.

## Motivation

While most Next.js boilerplates focus on individual developer needs with excessive complexity, **next-enterprise** prioritizes strategic simplicity for enterprise teams. It offers a streamlined foundation with high-impact features that maximize developer productivity and accelerate time-to-market for business-critical applications.

<a href="https://blazity.com/">
<picture>
  <source media="(prefers-color-scheme: dark)" srcset="/assets/blazity-logo-dark.svg">
  <source media="(prefers-color-scheme: light)" srcset="/assets/blazity-logo-light.svg">
  <img alt="Logo" align="right" height="80" src="/assets/blazity-logo-light.svg">
</picture>
</a>

> [!NOTE]
> **Blazity** is a group of Next.js architects. We help organizations architect, optimize, and deploy high-performance Next.js applications at scale. Contact us at [contact@blazity.com](https://blazity.com) if you’d like to talk about your project.



## Documentation

There is a separate documentation that explains its functionality, highlights core business values and technical decisions, provides guidelines for future development, and includes architectural diagrams.

We encourage you to [visit our docs (docs.blazity.com)](https://docs.blazity.com) to learn more

## Integrated features

### Boilerplate
With this template you will get all the boilerplate features included:

* [Next.js 15](https://nextjs.org/) - Performance-optimized configuration using App Directory
* [Tailwind CSS v4](https://tailwindcss.com/) - Utility-first CSS framework for efficient UI development
* [ESlint 9](https://eslint.org/) and [Prettier](https://prettier.io/) - Code consistency and error prevention
* [Corepack](https://github.com/nodejs/corepack) & [pnpm](https://pnpm.io/) as the package manager - For project management without compromises 
* [Strict TypeScript](https://www.typescriptlang.org/) - Enhanced type safety with carefully crafted config and [ts-reset](https://github.com/total-typescript/ts-reset) library
* [GitHub Actions](https://github.com/features/actions) - Pre-configured workflows including bundle size and performance tracking
* Perfect Lighthouse score - Optimized performance metrics
* [Bundle analyzer](https://www.npmjs.com/package/@next/bundle-analyzer) - Monitor and manage bundle size during development
* Testing suite - [Vitest](https://vitest.dev), [React Testing Library](https://testing-library.com/react), and [Playwright](https://playwright.dev/) for comprehensive testing
* [Storybook](https://storybook.js.org/) - Component development and documentation
* Advanced testing - Smoke and acceptance testing capabilities
* [Conventional commits](https://www.conventionalcommits.org/) - Standardized commit history management
* [Observability](https://opentelemetry.io/) - Open Telemetry integration
* [Absolute imports](https://nextjs.org/docs/advanced-features/module-path-aliases) - Simplified import structure
* [Health checks](https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/) - Kubernetes-compatible monitoring
* [Radix UI](https://www.radix-ui.com/) - Headless components for customization
* [CVA](http://cva.style/) (Class Variance Authority) - Consistent design system creation
* [Renovate BOT](https://www.whitesourcesoftware.com/free-developer-tools/renovate) - Automated dependency and security updates
* [Patch-package](https://www.npmjs.com/package/patch-package) - External dependency fixes without compromises
* Component relationship tools - Graph for managing coupling and cohesion
* [Semantic Release](https://github.com/semantic-release/semantic-release) - Automated changelog generation
* [T3 Env](https://env.t3.gg/) - Streamlined environment variable management

### Infrastructure & deployments

#### Vercel

Easily deploy your Next.js app with [Vercel](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=github&utm_campaign=next-enterprise) by clicking the button below:

[![Vercel](https://vercel.com/button)](https://vercel.com/new/git/external?repository-url=https://github.com/Blazity/next-enterprise)

#### Custom cloud infrastructure

**next-enterprise** offers dedicated infrastructure as code (IaC) solutions built with Terraform, designed specifically for deploying Next.js applications based on our extensive experience working with enterprise clients.

Learn more in our [documentation (docs.blazity.com)][docs] how to quickstart with the deployments using simple CLI.

#### Available cloud providers and theirs features:

* **AWS (Amazon Web Services)**
  * Automated provisioning of AWS infrastructure
  * Scalable & secure setup using:
     * VPC - Isolated network infrastructure
     * Elastic Container Service (ECS) - Container orchestration
     * Elastic Container Registry (ECR) - Container image storage
     * Application Load Balancer - Traffic distribution
     * S3 + CloudFront - Static asset delivery and caching
     * AWS WAF - Web Application Firewall protection
     * Redis Cluster - Caching
  * CI/CD ready - Continuous integration and deployment pipeline

*... more coming soon*

### Team & maintenance

**next-enterprise** is backed and maintained by [Blazity](https://blazity.com), providing up to date security features and integrated feature updates.

#### Active maintainers

- Igor Klepacki ([neg4n](https://github.com/neg4n)) - Open Source Software Developer
- Tomasz Czechowski ([tomaszczechowski](https://github.com/tomaszczechowski)) - Solutions Architect & DevOps
- Jakub Jabłoński ([jjablonski-it](https://github.com/jjablonski-it)) - Head of Integrations

#### All-time contributors
[bmstefanski](https://github.com/bmstefanski)

## License

MIT


[docs]: https://docs.blazity.com/next-enterprise/deployments/enterprise-cli


================================================
FILE: app/api/health/route.ts
================================================
export async function GET() {
  return Response.json({ status: "ok" })
}


================================================
FILE: app/layout.tsx
================================================
import "styles/tailwind.css"

export default function RootLayout({ children }: { children: React.ReactNode }) {
  return (
    <html lang="en">
      <body>{children}</body>
    </html>
  )
}


================================================
FILE: app/page.tsx
================================================
import { Metadata } from "next"
import { Button } from "components/Button/Button"

import { LP_GRID_ITEMS } from "lp-items"

export const metadata: Metadata = {
  title: "Next.js Enterprise Boilerplate",
  twitter: {
    card: "summary_large_image",
  },
  openGraph: {
    url: "https://next-enterprise.vercel.app/",
    images: [
      {
        width: 1200,
        height: 630,
        url: "https://raw.githubusercontent.com/Blazity/next-enterprise/main/.github/assets/project-logo.png",
      },
    ],
  },
}

export default function Web() {
  return (
    <>
      <section className="bg-white dark:bg-gray-900">
        <div className="mx-auto grid max-w-(--breakpoint-xl) px-4 py-8 text-center lg:py-16">
          <div className="mx-auto place-self-center">
            <h1 className="mb-4 max-w-2xl text-4xl leading-none font-extrabold tracking-tight md:text-5xl xl:text-6xl dark:text-white">
              Next.js Enterprise Boilerplate
            </h1>
            <p className="mb-6 max-w-2xl font-light text-gray-500 md:text-lg lg:mb-8 lg:text-xl dark:text-gray-400">
              Jumpstart your enterprise project with our feature-packed, high-performance Next.js boilerplate!
              Experience rapid UI development, AI-powered code reviews, and an extensive suite of tools for a smooth and
              enjoyable development process.
            </p>
            <Button href="https://github.com/Blazity/next-enterprise" className="mr-3">
              Get started
            </Button>
            <Button
              href="https://vercel.com/new/git/external?repository-url=https://github.com/Blazity/next-enterprise"
              intent="secondary"
            >
              Deploy Now
            </Button>
          </div>
        </div>
      </section>
      <section className="bg-white dark:bg-gray-900">
        <div className="mx-auto max-w-(--breakpoint-xl) px-4 py-8 sm:py-16 lg:px-6">
          <div className="justify-center space-y-8 md:grid md:grid-cols-2 md:gap-12 md:space-y-0 lg:grid-cols-3">
            {LP_GRID_ITEMS.map((singleItem) => (
              <div key={singleItem.title} className="flex flex-col items-center justify-center text-center">
                <div className="bg-primary-100 dark:bg-primary-900 mb-4 flex size-10 items-center justify-center rounded-full p-1.5 text-blue-700 lg:size-12">
                  {singleItem.icon}
                </div>
                <h3 className="mb-2 text-xl font-bold dark:text-white">{singleItem.title}</h3>
                <p className="text-gray-500 dark:text-gray-400">{singleItem.description}</p>
              </div>
            ))}
          </div>
        </div>
      </section>
    </>
  )
}


================================================
FILE: components/Button/Button.stories.tsx
================================================
import type { Meta, StoryObj } from "@storybook/react"
import { Button } from "./Button"

const meta: Meta<typeof Button> = {
  title: "Button",
  component: Button,
  args: {
    intent: "primary",
    underline: false,
    children: "Button",
    size: "lg",
  },
  argTypes: {
    intent: {
      options: ["primary", "secondary"],
      control: { type: "select" },
    },
    size: {
      options: ["sm", "lg"],
      control: { type: "select" },
    },
  },
}

type Story = StoryObj<typeof Button>

export const Default: Story = {
  render: (args) => <Button {...args} />,
}

export default meta


================================================
FILE: components/Button/Button.test.tsx
================================================
import { render, screen } from "@testing-library/react"
import { describe, expect, it } from "vitest"
import { Button } from "./Button"

describe("Button", () => {
  it("renders with children", () => {
    render(<Button href="/test">Click me</Button>)
    expect(screen.getByText("Click me")).toBeInTheDocument()
  })

  it("applies correct intent classes", () => {
    const { container } = render(
      <Button href="/test" intent="secondary">
        Secondary
      </Button>
    )
    const link = container.querySelector("a")
    expect(link).toHaveClass("bg-transparent")
    expect(link).toHaveClass("text-blue-400")
  })

  it("applies correct size classes", () => {
    const { container } = render(
      <Button href="/test" size="sm">
        Small
      </Button>
    )
    const link = container.querySelector("a")
    expect(link).toHaveClass("text-sm")
    expect(link).toHaveClass("min-w-20")
  })
})


================================================
FILE: components/Button/Button.tsx
================================================
import { cva, type VariantProps } from "class-variance-authority"

import { twMerge } from "tailwind-merge"

const button = cva(
  [
    "justify-center",
    "inline-flex",
    "items-center",
    "rounded-xl",
    "text-center",
    "border",
    "border-blue-400",
    "transition-colors",
    "delay-50",
  ],
  {
    variants: {
      intent: {
        primary: ["bg-blue-400", "text-white", "hover:enabled:bg-blue-700"],
        secondary: ["bg-transparent", "text-blue-400", "hover:enabled:bg-blue-400", "hover:enabled:text-white"],
      },
      size: {
        sm: ["min-w-20", "h-full", "min-h-10", "text-sm", "py-1.5", "px-4"],
        lg: ["min-w-32", "h-full", "min-h-12", "text-lg", "py-2.5", "px-6"],
      },
      underline: { true: ["underline"], false: [] },
    },
    defaultVariants: {
      intent: "primary",
      size: "lg",
    },
  }
)

export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLAnchorElement>, VariantProps<typeof button> {
  underline?: boolean
  href: string
}

export function Button({ className, intent, size, underline, ...props }: ButtonProps) {
  return (
    <a className={twMerge(button({ intent, size, className, underline }))} {...props}>
      {props.children}
    </a>
  )
}


================================================
FILE: components/Tooltip/Tooltip.tsx
================================================
"use client"

import * as RadixTooltip from "@radix-ui/react-tooltip"
import { cva, type VariantProps } from "class-variance-authority"
import React from "react"
import { twMerge } from "tailwind-merge"

const tooltipContent = cva([], {
  variants: {
    intent: {
      primary: ["rounded-md", "bg-zinc-700", "font-sans", "text-white"],
    },
    size: {
      md: ["px-4", "py-2.5", "text-xs"],
    },
  },
  defaultVariants: {
    intent: "primary",
    size: "md",
  },
})

const tooltipArrow = cva([], {
  variants: {
    intent: {
      primary: ["fill-zinc-700"],
    },
    size: {
      md: ["w-4", "h-2"],
    },
  },
  defaultVariants: {
    intent: "primary",
    size: "md",
  },
})

export interface TooltipProps extends VariantProps<typeof tooltipContent>, RadixTooltip.TooltipProps {
  explainer: React.ReactElement | string
  children: React.ReactElement
  className?: string
  withArrow?: boolean
  side?: "top" | "right" | "bottom" | "left"
}

export function Tooltip({
  children,
  explainer,
  open,
  defaultOpen,
  onOpenChange,
  intent,
  size,
  side = "top",
  className,
  withArrow,
}: TooltipProps) {
  return (
    <RadixTooltip.Provider>
      <RadixTooltip.Root open={open} defaultOpen={defaultOpen} onOpenChange={onOpenChange} delayDuration={200}>
        <RadixTooltip.Trigger asChild>{children}</RadixTooltip.Trigger>
        <RadixTooltip.Portal>
          <RadixTooltip.Content
            side={side}
            sideOffset={5}
            className={twMerge(tooltipContent({ intent, size, className }))}
          >
            {explainer}
            {withArrow ? <RadixTooltip.Arrow className={twMerge(tooltipArrow({ intent, size, className }))} /> : null}
          </RadixTooltip.Content>
        </RadixTooltip.Portal>
      </RadixTooltip.Root>
    </RadixTooltip.Provider>
  )
}


================================================
FILE: e2e/example.spec.ts
================================================
import { expect, test } from "@playwright/test"

test("has title", async ({ page }) => {
  await page.goto("./")

  await expect(page).toHaveTitle(/Next.js Enterprise Boilerplate/)
})


================================================
FILE: env.mjs
================================================
import { createEnv } from "@t3-oss/env-nextjs"
import { z } from "zod"

export const env = createEnv({
  server: {
    ANALYZE: z
      .enum(["true", "false"])
      .optional()
      .transform((value) => value === "true"),
  },
  client: {},
  runtimeEnv: {
    ANALYZE: process.env.ANALYZE,
  },
})


================================================
FILE: eslint.config.mjs
================================================
import * as fs from "fs"

// https://github.com/francoismassart/eslint-plugin-tailwindcss/pull/381
// import eslintPluginTailwindcss from "eslint-plugin-tailwindcss"
import eslintPluginImport from "eslint-plugin-import"
import eslintPluginNext from "@next/eslint-plugin-next"
import eslintPluginStorybook from "eslint-plugin-storybook"
import typescriptEslint from "typescript-eslint"

const eslintIgnore = [
  ".git/",
  ".next/",
  "node_modules/",
  "dist/",
  "build/",
  "coverage/",
  "*.min.js",
  "*.config.js",
  "*.d.ts",
]

const config = typescriptEslint.config(
  {
    ignores: eslintIgnore,
  },
  ...eslintPluginStorybook.configs["flat/recommended"],
  //  https://github.com/francoismassart/eslint-plugin-tailwindcss/pull/381
  // ...eslintPluginTailwindcss.configs["flat/recommended"],
  typescriptEslint.configs.recommended,
  eslintPluginImport.flatConfigs.recommended,
  {
    plugins: {
      "@next/next": eslintPluginNext,
    },
    rules: {
      ...eslintPluginNext.configs.recommended.rules,
      ...eslintPluginNext.configs["core-web-vitals"].rules,
    },
  },
  {
    settings: {
      tailwindcss: {
        callees: ["classnames", "clsx", "ctl", "cn", "cva"],
      },

      "import/resolver": {
        typescript: true,
        node: true,
      },
    },
    rules: {
      "@typescript-eslint/no-unused-vars": [
        "warn",
        {
          argsIgnorePattern: "^_",
          varsIgnorePattern: "^_",
        },
      ],
      "sort-imports": [
        "error",
        {
          ignoreCase: true,
          ignoreDeclarationSort: true,
        },
      ],
      "import/order": [
        "warn",
        {
          groups: ["external", "builtin", "internal", "sibling", "parent", "index"],
          pathGroups: [
            ...getDirectoriesToSort().map((singleDir) => ({
              pattern: `${singleDir}/**`,
              group: "internal",
            })),
            {
              pattern: "env",
              group: "internal",
            },
            {
              pattern: "theme",
              group: "internal",
            },
            {
              pattern: "public/**",
              group: "internal",
              position: "after",
            },
          ],
          pathGroupsExcludedImportTypes: ["internal"],
          alphabetize: {
            order: "asc",
            caseInsensitive: true,
          },
        },
      ],
    },
  }
)

function getDirectoriesToSort() {
  const ignoredSortingDirectories = [".git", ".next", ".vscode", "node_modules"]
  return fs
    .readdirSync(process.cwd())
    .filter((file) => fs.statSync(process.cwd() + "/" + file).isDirectory())
    .filter((f) => !ignoredSortingDirectories.includes(f))
}

export default config


================================================
FILE: git-conventional-commits.yaml
================================================
---
convention:
  commitTypes:
  - feat
  - fix
  - perf
  - refactor
  - style
  - test
  - build
  - ops
  - docs
  - chore
  - merge
  - revert
  commitScopes: []
  releaseTagGlobPattern: v[0-9]*.[0-9]*.[0-9]*
changelog:
  commitTypes:
  - feat
  - fix
  - perf
  - merge
  includeInvalidCommits: true
  commitIgnoreRegexPattern: "^WIP "
  headlines:
    feat: Features
    fix: Bug Fixes
    perf: Performance Improvements
    merge: Merges
    breakingChange: BREAKING CHANGES

  ## GitHub
  # commitUrl: https://github.com/ACCOUNT/REPOSITORY/commit/%commit%
  # commitRangeUrl: https://github.com/ACCOUNT/REPOSITORY/compare/%from%...%to%?diff=split

  ## GitHub Issues
  # issueRegexPattern: "#[0-9]+"
  # issueUrl: https://github.com/ACCOUNT/REPOSITORY/issues/%issue%

  ## Jira Issues
  # issueRegexPattern: "[A-Z][A-Z0-9]+-[0-9]+"
  # issueUrl: https://WORKSPACE.atlassian.net/browse/%issue%


================================================
FILE: instrumentation.ts
================================================
import { registerOTel } from "@vercel/otel"

export function register() {
  registerOTel("next-app")
}


================================================
FILE: lp-items.tsx
================================================
export const LP_GRID_ITEMS = [
  {
    title: "Next.js",
    description: "Fast by default, with config optimized for performance.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M12 18v-5.25m0 0a6.01 6.01 0 001.5-.189m-1.5.189a6.01 6.01 0 01-1.5-.189m3.75 7.478a12.06 12.06 0 01-4.5 0m3.75 2.383a14.406 14.406 0 01-3 0M14.25 18v-.192c0-.983.658-1.823 1.508-2.316a7.5 7.5 0 10-7.517 0c.85.493 1.509 1.333 1.509 2.316V18"
        />
      </svg>
    ),
  },
  {
    title: "Tailwind CSS",
    description: "A utility-first CSS framework for rapid UI development.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M4.5 12a7.5 7.5 0 0015 0m-15 0a7.5 7.5 0 1115 0m-15 0H3m16.5 0H21m-1.5 0H12m-8.457 3.077l1.41-.513m14.095-5.13l1.41-.513M5.106 17.785l1.15-.964m11.49-9.642l1.149-.964M7.501 19.795l.75-1.3m7.5-12.99l.75-1.3m-6.063 16.658l.26-1.477m2.605-14.772l.26-1.477m0 17.726l-.26-1.477M10.698 4.614l-.26-1.477M16.5 19.794l-.75-1.299M7.5 4.205L12 12m6.894 5.785l-1.149-.964M6.256 7.178l-1.15-.964m15.352 8.864l-1.41-.513M4.954 9.435l-1.41-.514M12.002 12l-3.75 6.495"
        />
      </svg>
    ),
  },
  {
    title: "ESlint & Prettier",
    description: "For clean, consistent, and error-free code.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path strokeLinecap="round" strokeLinejoin="round" d="M4.5 12.75l6 6 9-13.5" />
      </svg>
    ),
  },
  {
    title: "Extremely strict TypeScript",
    description: "With `ts-reset` library for ultimate type safety.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M9 12.75L11.25 15 15 9.75m-3-7.036A11.959 11.959 0 013.598 6 11.99 11.99 0 003 9.749c0 5.592 3.824 10.29 9 11.623 5.176-1.332 9-6.03 9-11.622 0-1.31-.21-2.571-.598-3.751h-.152c-3.196 0-6.1-1.248-8.25-3.285z"
        />
      </svg>
    ),
  },
  {
    title: "Bundle analyzer plugin",
    description: "Keep an eye on your bundle size.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M3 13.125C3 12.504 3.504 12 4.125 12h2.25c.621 0 1.125.504 1.125 1.125v6.75C7.5 20.496 6.996 21 6.375 21h-2.25A1.125 1.125 0 013 19.875v-6.75zM9.75 8.625c0-.621.504-1.125 1.125-1.125h2.25c.621 0 1.125.504 1.125 1.125v11.25c0 .621-.504 1.125-1.125 1.125h-2.25a1.125 1.125 0 01-1.125-1.125V8.625zM16.5 4.125c0-.621.504-1.125 1.125-1.125h2.25C20.496 3 21 3.504 21 4.125v15.75c0 .621-.504 1.125-1.125 1.125h-2.25a1.125 1.125 0 01-1.125-1.125V4.125z"
        />
      </svg>
    ),
  },
  {
    title: "Vitest & React Testing Library",
    description: "For rock-solid unit and integration tests.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M9.75 3.104v5.714a2.25 2.25 0 01-.659 1.591L5 14.5M9.75 3.104c-.251.023-.501.05-.75.082m.75-.082a24.301 24.301 0 014.5 0m0 0v5.714c0 .597.237 1.17.659 1.591L19.8 15.3M14.25 3.104c.251.023.501.05.75.082M19.8 15.3l-1.57.393A9.065 9.065 0 0112 15a9.065 9.065 0 00-6.23-.693L5 14.5m14.8.8l1.402 1.402c1.232 1.232.65 3.318-1.067 3.611A48.309 48.309 0 0112 21c-2.773 0-5.491-.235-8.135-.687-1.718-.293-2.3-2.379-1.067-3.61L5 14.5"
        />
      </svg>
    ),
  },
  {
    title: "Playwright",
    description: "Write end-to-end tests like a pro.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M3.75 3v11.25A2.25 2.25 0 006 16.5h2.25M3.75 3h-1.5m1.5 0h16.5m0 0h1.5m-1.5 0v11.25A2.25 2.25 0 0118 16.5h-2.25m-7.5 0h7.5m-7.5 0l-1 3m8.5-3l1 3m0 0l.5 1.5m-.5-1.5h-9.5m0 0l-.5 1.5M9 11.25v1.5M12 9v3.75m3-6v6"
        />
      </svg>
    ),
  },
  {
    title: "Storybook",
    description: "Create, test, and showcase your components.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M12 6.042A8.967 8.967 0 006 3.75c-1.052 0-2.062.18-3 .512v14.25A8.987 8.987 0 016 18c2.305 0 4.408.867 6 2.292m0-14.25a8.966 8.966 0 016-2.292c1.052 0 2.062.18 3 .512v14.25A8.987 8.987 0 0018 18a8.967 8.967 0 00-6 2.292m0-14.25v14.25"
        />
      </svg>
    ),
  },
  {
    title: "Smoke Testing & Acceptance Tests",
    description: "For confidence in your deployments.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M11.35 3.836c-.065.21-.1.433-.1.664 0 .414.336.75.75.75h4.5a.75.75 0 00.75-.75 2.25 2.25 0 00-.1-.664m-5.8 0A2.251 2.251 0 0113.5 2.25H15c1.012 0 1.867.668 2.15 1.586m-5.8 0c-.376.023-.75.05-1.124.08C9.095 4.01 8.25 4.973 8.25 6.108V8.25m8.9-4.414c.376.023.75.05 1.124.08 1.131.094 1.976 1.057 1.976 2.192V16.5A2.25 2.25 0 0118 18.75h-2.25m-7.5-10.5H4.875c-.621 0-1.125.504-1.125 1.125v11.25c0 .621.504 1.125 1.125 1.125h9.75c.621 0 1.125-.504 1.125-1.125V18.75m-7.5-10.5h6.375c.621 0 1.125.504 1.125 1.125v9.375m-8.25-3l1.5 1.5 3-3.75"
        />
      </svg>
    ),
  },
  {
    title: "Conventional commits git hook",
    description: "Keep your commit history neat and tidy.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M6.75 7.5l3 2.25-3 2.25m4.5 0h3m-9 8.25h13.5A2.25 2.25 0 0021 18V6a2.25 2.25 0 00-2.25-2.25H5.25A2.25 2.25 0 003 6v12a2.25 2.25 0 002.25 2.25z"
        />
      </svg>
    ),
  },
  {
    title: "Observability",
    description: "Open Telemetry integration for seamless monitoring.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M2.036 12.322a1.012 1.012 0 010-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178z"
        />
        <path strokeLinecap="round" strokeLinejoin="round" d="M15 12a3 3 0 11-6 0 3 3 0 016 0z" />
      </svg>
    ),
  },
  {
    title: "Absolute imports",
    description: "No more spaghetti imports.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M13.19 8.688a4.5 4.5 0 011.242 7.244l-4.5 4.5a4.5 4.5 0 01-6.364-6.364l1.757-1.757m13.35-.622l1.757-1.757a4.5 4.5 0 00-6.364-6.364l-4.5 4.5a4.5 4.5 0 001.242 7.244"
        />
      </svg>
    ),
  },
  {
    title: "Health checks",
    description: "Kubernetes-compatible for robust deployments.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M21 8.25c0-2.485-2.099-4.5-4.688-4.5-1.935 0-3.597 1.126-4.312 2.733-.715-1.607-2.377-2.733-4.313-2.733C5.1 3.75 3 5.765 3 8.25c0 7.22 9 12 9 12s9-4.78 9-12z"
        />
      </svg>
    ),
  },
  {
    title: "Radix UI",
    description: "Headless UI components for endless customization.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M14.25 6.087c0-.355.186-.676.401-.959.221-.29.349-.634.349-1.003 0-1.036-1.007-1.875-2.25-1.875s-2.25.84-2.25 1.875c0 .369.128.713.349 1.003.215.283.401.604.401.959v0a.64.64 0 01-.657.643 48.39 48.39 0 01-4.163-.3c.186 1.613.293 3.25.315 4.907a.656.656 0 01-.658.663v0c-.355 0-.676-.186-.959-.401a1.647 1.647 0 00-1.003-.349c-1.036 0-1.875 1.007-1.875 2.25s.84 2.25 1.875 2.25c.369 0 .713-.128 1.003-.349.283-.215.604-.401.959-.401v0c.31 0 .555.26.532.57a48.039 48.039 0 01-.642 5.056c1.518.19 3.058.309 4.616.354a.64.64 0 00.657-.643v0c0-.355-.186-.676-.401-.959a1.647 1.647 0 01-.349-1.003c0-1.035 1.008-1.875 2.25-1.875 1.243 0 2.25.84 2.25 1.875 0 .369-.128.713-.349 1.003-.215.283-.4.604-.4.959v0c0 .333.277.599.61.58a48.1 48.1 0 005.427-.63 48.05 48.05 0 00.582-4.717.532.532 0 00-.533-.57v0c-.355 0-.676.186-.959.401-.29.221-.634.349-1.003.349-1.035 0-1.875-1.007-1.875-2.25s.84-2.25 1.875-2.25c.37 0 .713.128 1.003.349.283.215.604.401.96.401v0a.656.656 0 00.658-.663 48.422 48.422 0 00-.37-5.36c-1.886.342-3.81.574-5.766.689a.578.578 0 01-.61-.58v0z"
        />
      </svg>
    ),
  },
  {
    title: "CVA",
    description: "Create a consistent, reusable, and atomic design system.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M21 7.5l-2.25-1.313M21 7.5v2.25m0-2.25l-2.25 1.313M3 7.5l2.25-1.313M3 7.5l2.25 1.313M3 7.5v2.25m9 3l2.25-1.313M12 12.75l-2.25-1.313M12 12.75V15m0 6.75l2.25-1.313M12 21.75V19.5m0 2.25l-2.25-1.313m0-16.875L12 2.25l2.25 1.313M21 14.25v2.25l-2.25 1.313m-13.5 0L3 16.5v-2.25"
        />
      </svg>
    ),
  },
  {
    title: "Renovate BOT",
    description: "Auto-updating dependencies, so you can focus on coding.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M3.75 13.5l10.5-11.25L12 10.5h8.25L9.75 21.75 12 13.5H3.75z"
        />
      </svg>
    ),
  },
  {
    title: "Patch-package",
    description: "Fix external dependencies without losing your mind.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M20.25 7.5l-.625 10.632a2.25 2.25 0 01-2.247 2.118H6.622a2.25 2.25 0 01-2.247-2.118L3.75 7.5M10 11.25h4M3.375 7.5h17.25c.621 0 1.125-.504 1.125-1.125v-1.5c0-.621-.504-1.125-1.125-1.125H3.375c-.621 0-1.125.504-1.125 1.125v1.5c0 .621.504 1.125 1.125 1.125z"
        />
      </svg>
    ),
  },
  {
    title: "Components coupling & cohesion graph",
    description: "A tool for managing component relationships.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path strokeLinecap="round" strokeLinejoin="round" d="M10.5 6a7.5 7.5 0 107.5 7.5h-7.5V6z" />
        <path strokeLinecap="round" strokeLinejoin="round" d="M13.5 10.5H21A7.5 7.5 0 0013.5 3v7.5z" />
      </svg>
    ),
  },
  {
    title: "GitHub Actions",
    description: "Pre-configured actions for smooth workflows, including Bundle Size and performance stats.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M5.25 5.653c0-.856.917-1.398 1.667-.986l11.54 6.348a1.125 1.125 0 010 1.971l-11.54 6.347a1.125 1.125 0 01-1.667-.985V5.653z"
        />
      </svg>
    ),
  },
  {
    title: "Automated ChatGPT Code Reviews",
    description: "Stay on the cutting edge with AI-powered code reviews!",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M2.25 12.76c0 1.6 1.123 2.994 2.707 3.227 1.068.157 2.148.279 3.238.364.466.037.893.281 1.153.671L12 21l2.652-3.978c.26-.39.687-.634 1.153-.67 1.09-.086 2.17-.208 3.238-.365 1.584-.233 2.707-1.626 2.707-3.228V6.741c0-1.602-1.123-2.995-2.707-3.228A48.394 48.394 0 0012 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018z"
        />
      </svg>
    ),
  },
  {
    title: "Semantic Release",
    description: "For automatic changelog generation.",
    icon: (
      <svg
        xmlns="http://www.w3.org/2000/svg"
        fill="none"
        viewBox="0 0 24 24"
        strokeWidth={1.5}
        stroke="currentColor"
        className="h-6 w-6"
      >
        <path
          strokeLinecap="round"
          strokeLinejoin="round"
          d="M15 11.25l-3-3m0 0l-3 3m3-3v7.5M21 12a9 9 0 11-18 0 9 9 0 0118 0z"
        />
      </svg>
    ),
  },
]


================================================
FILE: next-env.d.ts
================================================
/// <reference types="next" />
/// <reference types="next/image-types/global" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.


================================================
FILE: next.config.ts
================================================
import withBundleAnalyzer from "@next/bundle-analyzer"
import { type NextConfig } from "next"

import { env } from "./env.mjs"

const config: NextConfig = {
  reactStrictMode: true,
  logging: {
    fetches: {
      fullUrl: true,
    },
  },
  rewrites: async () => [
    { source: "/healthz", destination: "/api/health" },
    { source: "/api/healthz", destination: "/api/health" },
    { source: "/health", destination: "/api/health" },
    { source: "/ping", destination: "/api/health" },
  ],
}

export default env.ANALYZE ? withBundleAnalyzer({ enabled: env.ANALYZE })(config) : config


================================================
FILE: package.json
================================================
{
  "name": "next-enterprise",
  "version": "0.0.0",
  "private": true,
  "scripts": {
    "dev": "cross-env FORCE_COLOR=1 next dev --turbo",
    "build": "next build",
    "start": "next start",
    "lint": "next lint",
    "lint:fix": "next lint --fix",
    "prettier": "prettier --check \"**/*.{js,jsx,ts,tsx}\"",
    "prettier:fix": "prettier --write \"**/*.{js,jsx,ts,tsx}\"",
    "analyze": "cross-env ANALYZE=true pnpm run build",
    "storybook": "cross-env FORCE_COLOR=1 storybook dev -p 6006",
    "test-storybook": "cross-env FORCE_COLOR=1 test-storybook",
    "build-storybook": "cross-env FORCE_COLOR=1 storybook build",
    "test": "cross-env FORCE_COLOR=1 vitest",
    "test:watch": "cross-env FORCE_COLOR=1 vitest --watch",
    "test:ui": "cross-env FORCE_COLOR=1 vitest --ui",
    "test:coverage": "cross-env FORCE_COLOR=1 vitest --coverage",
    "e2e:headless": "playwright test",
    "e2e:ui": "playwright test --ui",
    "format": "prettier --write \"**/*.{ts,tsx,md}\"",
    "postinstall": "npx patch-package -y",
    "coupling-graph": "npx madge --extensions js,jsx,ts,tsx,css,md,mdx ./ --exclude '.next|tailwind.config.js|reset.d.ts|prettier.config.js|postcss.config.js|playwright.config.ts|next.config.js|next-env.d.ts|instrumentation.ts|e2e/|README.md|.storybook/|.eslintrc.js' --image graph.svg"
  },
  "dependencies": {
    "@next/bundle-analyzer": "^15.3.1",
    "@radix-ui/react-accordion": "^1.2.12",
    "@radix-ui/react-checkbox": "^1.3.3",
    "@radix-ui/react-dialog": "^1.1.15",
    "@radix-ui/react-dropdown-menu": "^2.1.16",
    "@radix-ui/react-form": "^0.1.8",
    "@radix-ui/react-label": "^2.1.8",
    "@radix-ui/react-popover": "^1.1.15",
    "@radix-ui/react-radio-group": "^1.3.8",
    "@radix-ui/react-scroll-area": "^1.2.10",
    "@radix-ui/react-select": "^2.2.6",
    "@radix-ui/react-slider": "^1.3.6",
    "@radix-ui/react-switch": "^1.2.6",
    "@radix-ui/react-tabs": "^1.1.13",
    "@radix-ui/react-toggle-group": "^1.1.11",
    "@radix-ui/react-tooltip": "^1.2.8",
    "@semantic-release/changelog": "^6.0.3",
    "@semantic-release/commit-analyzer": "^13.0.1",
    "@semantic-release/git": "^10.0.1",
    "@semantic-release/github": "^12.0.6",
    "@semantic-release/npm": "^13.1.5",
    "@semantic-release/release-notes-generator": "^14.1.0",
    "@t3-oss/env-nextjs": "^0.13.10",
    "@vercel/otel": "^1.12.0",
    "class-variance-authority": "^0.7.1",
    "lodash": "^4.17.23",
    "next": "15.5.10",
    "react": "^19.2.4",
    "react-dom": "^19.2.4",
    "tailwind-merge": "^3.5.0",
    "zod": "^3.24.4"
  },
  "devDependencies": {
    "@babel/core": "^7.29.0",
    "@babel/plugin-syntax-flow": "^7.28.6",
    "@babel/plugin-transform-optional-chaining": "^7.28.6",
    "@babel/plugin-transform-react-jsx": "^7.28.6",
    "@eslint/eslintrc": "^3.3.5",
    "@next/eslint-plugin-next": "15.1.6",
    "@opentelemetry/api": "1.7.0",
    "@opentelemetry/resources": "1.18.1",
    "@opentelemetry/sdk-node": "0.45.1",
    "@opentelemetry/sdk-trace-node": "1.18.1",
    "@opentelemetry/semantic-conventions": "1.40.0",
    "@playwright/test": "^1.58.2",
    "@storybook/addon-controls": "^8.6.14",
    "@storybook/addon-essentials": "^8.6.14",
    "@storybook/addon-interactions": "^8.6.14",
    "@storybook/addon-links": "^8.6.14",
    "@storybook/blocks": "^8.6.14",
    "@storybook/nextjs": "^8.6.14",
    "@storybook/react": "^8.6.14",
    "@storybook/test": "^8.6.18",
    "@storybook/test-runner": "^0.21.3",
    "@tailwindcss/postcss": "^4.2.1",
    "@testing-library/jest-dom": "^6.9.1",
    "@testing-library/react": "^16.3.2",
    "@total-typescript/ts-reset": "^0.6.1",
    "@types/node": "^22.15.0",
    "@types/react": "^19.2.14",
    "@types/react-dom": "^19.2.3",
    "@typescript-eslint/eslint-plugin": "^8.57.1",
    "@vitejs/plugin-react": "^4.7.0",
    "@vitest/ui": "^3.2.4",
    "all-contributors-cli": "^6.26.1",
    "cross-env": "^7.0.3",
    "eslint": "^9.26.0",
    "eslint-config-next": "15.1.6",
    "eslint-config-prettier": "^10.1.8",
    "eslint-plugin-import": "^2.32.0",
    "eslint-plugin-storybook": "^0.11.6",
    "eslint-plugin-tailwindcss": "^3.18.2",
    "fetch-mock": "^12.6.0",
    "gzip-size": "6.0.0",
    "jsdom": "^26.1.0",
    "mkdirp": "^3.0.1",
    "patch-package": "^8.0.1",
    "postcss": "^8.5.8",
    "postcss-import": "^16.1.1",
    "postinstall-postinstall": "^2.1.0",
    "prettier": "^3.8.1",
    "prettier-plugin-tailwindcss": "^0.7.2",
    "semantic-release": "^25.0.3",
    "storybook": "^8.6.18",
    "tailwindcss": "^4.2.1",
    "tsc": "^2.0.4",
    "typed-query-selector": "^2.12.1",
    "typescript": "^5.9.3",
    "typescript-eslint": "^8.57.1",
    "vite-tsconfig-paths": "^5.1.4",
    "vitest": "^3.2.4",
    "webpack": "5.99.9"
  },
  "engines": {
    "node": ">=20.0.0"
  },
  "packageManager": "pnpm@10.0.0",
  "pnpm": {
    "overrides": {
      "tmp@<=0.2.3": ">=0.2.4"
    }
  }
}


================================================
FILE: playwright.config.ts
================================================
import { defineConfig, devices } from "@playwright/test"

/**
 * Read environment variables from file.
 * https://github.com/motdotla/dotenv
 */
// require('dotenv').config();

/**
 * See https://playwright.dev/docs/test-configuration.
 */
export default defineConfig({
  testDir: "./e2e",
  /* Run tests in files in parallel */
  fullyParallel: true,
  /* Fail the build on CI if you accidentally left test.only in the source code. */
  forbidOnly: !!process.env.CI,
  /* Retry on CI only */
  retries: process.env.CI ? 2 : 0,
  /* Opt out of parallel tests on CI. */
  workers: process.env.CI ? 1 : undefined,
  /* Reporter to use. See https://playwright.dev/docs/test-reporters */
  reporter: "html",
  /* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
  use: {
    /* Base URL to use in actions like `await page.goto('/')`. */
    baseURL: "http://127.0.0.1:3000",

    /* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */
    trace: "on-first-retry",
  },

  /* Configure projects for major browsers */
  projects: [
    {
      name: "chromium",
      use: { ...devices["Desktop Chrome"] },
    },

    {
      name: "firefox",
      use: { ...devices["Desktop Firefox"] },
    },

    {
      name: "webkit",
      use: { ...devices["Desktop Safari"] },
    },

    /* Test against mobile viewports. */
    // {
    //   name: 'Mobile Chrome',
    //   use: { ...devices['Pixel 5'] },
    // },
    // {
    //   name: 'Mobile Safari',
    //   use: { ...devices['iPhone 12'] },
    // },

    /* Test against branded browsers. */
    // {
    //   name: 'Microsoft Edge',
    //   use: { ...devices['Desktop Edge'], channel: 'msedge' },
    // },
    // {
    //   name: 'Google Chrome',
    //   use: { ..devices['Desktop Chrome'], channel: 'chrome' },
    // },
  ],

  /* Run your local dev server before starting the tests */
  webServer: {
    command: "pnpm dev",
    url: "http://127.0.0.1:3000",
    reuseExistingServer: !process.env.CI,
  },
})


================================================
FILE: postcss.config.js
================================================
module.exports = {
  plugins: {
    "postcss-import": {},
    "@tailwindcss/postcss": {},
  },
}


================================================
FILE: prettier.config.js
================================================
module.exports = {
  plugins: ["prettier-plugin-tailwindcss"],
  trailingComma: "es5",
  tabWidth: 2,
  printWidth: 120,
  semi: false,
}


================================================
FILE: renovate.json
================================================
{
  "$schema": "https://docs.renovatebot.com/renovate-schema.json",
  "extends": [
    "config:base"
  ],
  "packageRules": [
    {
      "enabled": false,
      "matchPackagePatterns": ["*"]
    }
  ],
  "vulnerabilityAlerts": {
    "enabled": true
  },
  "osvVulnerabilityAlerts": true
}


================================================
FILE: report-bundle-size.js
================================================
#!/usr/bin/env node
/* eslint-disable no-console */
/**
 * Copyright (c) HashiCorp, Inc.
 * SPDX-License-Identifier: MPL-2.0
 */

// edited to work with the appdir by @raphaelbadia

const gzSize = require("gzip-size")
const mkdirp = require("mkdirp")
const fs = require("fs")
const path = require("path")

// Pull options from `package.json`
const options = getOptions()
const BUILD_OUTPUT_DIRECTORY = getBuildOutputDirectory(options)

// first we check to make sure that the build output directory exists
const nextMetaRoot = path.join(process.cwd(), BUILD_OUTPUT_DIRECTORY)
try {
  fs.accessSync(nextMetaRoot, fs.constants.R_OK)
} catch (err) {
  console.error(
    `No build output found at "${nextMetaRoot}" - you may not have your working directory set correctly, or not have run "next build".`
  )
  process.exit(1)
}

// if so, we can import the build manifest
const buildMeta = require(path.join(nextMetaRoot, "build-manifest.json"))
const appDirMeta = require(path.join(nextMetaRoot, "app-build-manifest.json"))

// this memory cache ensures we dont read any script file more than once
// bundles are often shared between pages
const memoryCache = {}

// since _app is the template that all other pages are rendered into,
// every page must load its scripts. we'll measure its size here
const globalBundle = buildMeta.pages["/_app"]
const globalBundleSizes = getScriptSizes(globalBundle)

// next, we calculate the size of each page's scripts, after
// subtracting out the global scripts
const allPageSizes = Object.values(buildMeta.pages).reduce((acc, scriptPaths, i) => {
  const pagePath = Object.keys(buildMeta.pages)[i]
  const scriptSizes = getScriptSizes(scriptPaths.filter((scriptPath) => !globalBundle.includes(scriptPath)))

  acc[pagePath] = scriptSizes

  return acc
}, {})

const globalAppDirBundle = buildMeta.rootMainFiles
const globalAppDirBundleSizes = getScriptSizes(globalAppDirBundle)

const allAppDirSizes = Object.values(appDirMeta.pages).reduce((acc, scriptPaths, i) => {
  const pagePath = Object.keys(appDirMeta.pages)[i]
  const scriptSizes = getScriptSizes(scriptPaths.filter((scriptPath) => !globalAppDirBundle.includes(scriptPath)))
  acc[pagePath] = scriptSizes

  return acc
}, {})

// format and write the output
const rawData = JSON.stringify({
  ...allAppDirSizes,
  __global: globalAppDirBundleSizes,
})

// log ouputs to the gh actions panel
console.log(rawData)

mkdirp.sync(path.join(nextMetaRoot, "analyze/"))
fs.writeFileSync(path.join(nextMetaRoot, "analyze/__bundle_analysis.json"), rawData)

// --------------
// Util Functions
// --------------

// given an array of scripts, return the total of their combined file sizes
function getScriptSizes(scriptPaths) {
  const res = scriptPaths.reduce(
    (acc, scriptPath) => {
      const [rawSize, gzipSize] = getScriptSize(scriptPath)
      acc.raw += rawSize
      acc.gzip += gzipSize

      return acc
    },
    { raw: 0, gzip: 0 }
  )

  return res
}

// given an individual path to a script, return its file size
function getScriptSize(scriptPath) {
  const encoding = "utf8"
  const p = path.join(nextMetaRoot, scriptPath)

  let rawSize, gzipSize
  if (Object.keys(memoryCache).includes(p)) {
    rawSize = memoryCache[p][0]
    gzipSize = memoryCache[p][1]
  } else {
    const textContent = fs.readFileSync(p, encoding)
    rawSize = Buffer.byteLength(textContent, encoding)
    gzipSize = gzSize.sync(textContent)
    memoryCache[p] = [rawSize, gzipSize]
  }

  return [rawSize, gzipSize]
}

/**
 * Reads options from `package.json`
 */
function getOptions(pathPrefix = process.cwd()) {
  const pkg = require(path.join(pathPrefix, "package.json"))

  return { ...pkg.nextBundleAnalysis, name: pkg.name }
}

/**
 * Gets the output build directory, defaults to `.next`
 *
 * @param {object} options the options parsed from package.json.nextBundleAnalysis using `getOptions`
 * @returns {string}
 */
function getBuildOutputDirectory(options) {
  return options.buildOutputDirectory || ".next"
}


================================================
FILE: reset.d.ts
================================================
import "@total-typescript/ts-reset"
import "typed-query-selector/strict"


================================================
FILE: styles/tailwind.css
================================================
@import 'tailwindcss';

/*
  The default border color has changed to `currentColor` in Tailwind CSS v4,
  so we've added these compatibility styles to make sure everything still
  looks the same as it did with Tailwind CSS v3.

  If we ever want to remove these styles, we need to add an explicit border
  color utility to any element that depends on these defaults.
*/
@layer base {
  *,
  ::after,
  ::before,
  ::backdrop,
  ::file-selector-button {
    border-color: var(--color-gray-200, currentColor);
  }
}


================================================
FILE: tsconfig.json
================================================
{
  "$schema": "https://json.schemastore.org/tsconfig",
  "display": "Next.js",
  "compilerOptions": {
    "target": "es5",
    "lib": ["dom", "dom.iterable", "esnext"],
    "allowJs": true,
    "skipLibCheck": true,
    "strict": true,
    "noUncheckedIndexedAccess": true,
    "forceConsistentCasingInFileNames": true,
    "noEmit": true,
    "esModuleInterop": true,
    "module": "esnext",
    "moduleResolution": "node",
    "resolveJsonModule": true,
    "isolatedModules": true,
    "jsx": "preserve",
    "incremental": true,
    "baseUrl": ".",
    "types": ["node", "vitest/globals", "@testing-library/jest-dom"],
    "plugins": [
      {
        "name": "next"
      }
    ]
  },
  "include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", "**/*.mjs", "vitest.config.ts", ".next/types/**/*.ts", "eslint.config.mjs"],
  "exclude": ["node_modules"]
}


================================================
FILE: vercel.json
================================================
{
  "$schema": "https://openapi.vercel.sh/vercel.json",
  "installCommand": "corepack enable && pnpm install"
}


================================================
FILE: vitest.config.ts
================================================
import { defineConfig } from "vitest/config"
import react from "@vitejs/plugin-react"
import tsconfigPaths from "vite-tsconfig-paths"

export default defineConfig({
  plugins: [tsconfigPaths(), react()],
  test: {
    environment: "jsdom",
    setupFiles: "./vitest.setup.ts",
    globals: true,
    include: ["**/*.test.{ts,tsx}", "**/*.spec.{ts,tsx}"],
    exclude: ["**/node_modules/**", "**/dist/**", "**/e2e/**", ".next/**"],
  },
})


================================================
FILE: vitest.setup.ts
================================================
import "@testing-library/jest-dom"
Download .txt
gitextract_1vk2cap0/

├── .all-contributorsrc
├── .github/
│   ├── nodejs.version
│   └── workflows/
│       ├── check.yml
│       ├── nextjs_bundle_analysis.yml
│       └── playwright.yml
├── .gitignore
├── .pre-commit-config.yaml
├── .prettierignore
├── .releaserc
├── .storybook/
│   ├── main.ts
│   └── preview.ts
├── .vscode/
│   └── settings.json
├── LICENSE
├── README.md
├── app/
│   ├── api/
│   │   └── health/
│   │       └── route.ts
│   ├── layout.tsx
│   └── page.tsx
├── components/
│   ├── Button/
│   │   ├── Button.stories.tsx
│   │   ├── Button.test.tsx
│   │   └── Button.tsx
│   └── Tooltip/
│       └── Tooltip.tsx
├── e2e/
│   └── example.spec.ts
├── env.mjs
├── eslint.config.mjs
├── git-conventional-commits.yaml
├── instrumentation.ts
├── lp-items.tsx
├── next-env.d.ts
├── next.config.ts
├── package.json
├── playwright.config.ts
├── postcss.config.js
├── prettier.config.js
├── renovate.json
├── report-bundle-size.js
├── reset.d.ts
├── styles/
│   └── tailwind.css
├── tsconfig.json
├── vercel.json
├── vitest.config.ts
└── vitest.setup.ts
Download .txt
SYMBOL INDEX (16 symbols across 10 files)

FILE: app/api/health/route.ts
  function GET (line 1) | async function GET() {

FILE: app/layout.tsx
  function RootLayout (line 3) | function RootLayout({ children }: { children: React.ReactNode }) {

FILE: app/page.tsx
  function Web (line 23) | function Web() {

FILE: components/Button/Button.stories.tsx
  type Story (line 25) | type Story = StoryObj<typeof Button>

FILE: components/Button/Button.tsx
  type ButtonProps (line 36) | interface ButtonProps extends React.ButtonHTMLAttributes<HTMLAnchorEleme...
  function Button (line 41) | function Button({ className, intent, size, underline, ...props }: Button...

FILE: components/Tooltip/Tooltip.tsx
  type TooltipProps (line 38) | interface TooltipProps extends VariantProps<typeof tooltipContent>, Radi...
  function Tooltip (line 46) | function Tooltip({

FILE: eslint.config.mjs
  function getDirectoriesToSort (line 100) | function getDirectoriesToSort() {

FILE: instrumentation.ts
  function register (line 3) | function register() {

FILE: lp-items.tsx
  constant LP_GRID_ITEMS (line 1) | const LP_GRID_ITEMS = [

FILE: report-bundle-size.js
  constant BUILD_OUTPUT_DIRECTORY (line 17) | const BUILD_OUTPUT_DIRECTORY = getBuildOutputDirectory(options)
  function getScriptSizes (line 82) | function getScriptSizes(scriptPaths) {
  function getScriptSize (line 98) | function getScriptSize(scriptPath) {
  function getOptions (line 119) | function getOptions(pathPrefix = process.cwd()) {
  function getBuildOutputDirectory (line 131) | function getBuildOutputDirectory(options) {
Condensed preview — 41 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (63K chars).
[
  {
    "path": ".all-contributorsrc",
    "chars": 1061,
    "preview": "{\n  \"projectName\": \"next-enterprise\",\n  \"projectOwner\": \"Blazity\",\n  \"repoType\": \"github\",\n  \"repoHost\": \"https://github"
  },
  {
    "path": ".github/nodejs.version",
    "chars": 8,
    "preview": "v24.3.0\n"
  },
  {
    "path": ".github/workflows/check.yml",
    "chars": 1177,
    "preview": "name: Check\n\non:\n  push:\n    branches:\n      - main\n      - master\n      - develop\n  pull_request:\n  workflow_dispatch:\n"
  },
  {
    "path": ".github/workflows/nextjs_bundle_analysis.yml",
    "chars": 4253,
    "preview": "name: \"Next.js Bundle Analysis\"\n\non:\n  push:\n    branches:\n      - main\n      - develop\n  pull_request:\n    branches:\n  "
  },
  {
    "path": ".github/workflows/playwright.yml",
    "chars": 1003,
    "preview": "name: Playwright Tests\non:\n  push:\n    branches:\n      - main\n      - master\n      - develop\n  pull_request: null\n  work"
  },
  {
    "path": ".gitignore",
    "chars": 468,
    "preview": "# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.\n\n# dependencies\nnode_modules\n.pnp\n"
  },
  {
    "path": ".pre-commit-config.yaml",
    "chars": 128,
    "preview": "repos:\n  - repo: https://github.com/qoomon/git-conventional-commits\n    rev: v2.6.3\n    hooks:\n      - id: conventional-"
  },
  {
    "path": ".prettierignore",
    "chars": 18,
    "preview": ".next\nnode_modules"
  },
  {
    "path": ".releaserc",
    "chars": 306,
    "preview": "{\n  branches: [\"main\"],\n  \"plugins\":\n    [\n      [\"@semantic-release/npm\", { \"npmPublish\": false }],\n      \"@semantic-re"
  },
  {
    "path": ".storybook/main.ts",
    "chars": 686,
    "preview": "import type { StorybookConfig } from \"@storybook/nextjs\"\nconst config: StorybookConfig = {\n  stories: [\"../components/**"
  },
  {
    "path": ".storybook/preview.ts",
    "chars": 314,
    "preview": "import type { Preview } from \"@storybook/react\"\n\nimport \"../styles/tailwind.css\"\n\nconst preview: Preview = {\n  parameter"
  },
  {
    "path": ".vscode/settings.json",
    "chars": 154,
    "preview": "{\n  \"tailwindCSS.experimental.classRegex\": [\n    [\"cva(?:<[^>]*>)?(([^)]*))\", \"[\\\"'`]([^\\\"'`]*).*?[\\\"'`]\", \"(?:twMerge|t"
  },
  {
    "path": "LICENSE",
    "chars": 1064,
    "preview": "MIT License\n\nCopyright (c) 2023 Blazity\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof"
  },
  {
    "path": "README.md",
    "chars": 6137,
    "preview": "\n# [Next.js Enterprise Boilerplate](https://blazity.com/open-source/nextjs-enterprise-boilerplate) \n\nA production-ready "
  },
  {
    "path": "app/api/health/route.ts",
    "chars": 73,
    "preview": "export async function GET() {\n  return Response.json({ status: \"ok\" })\n}\n"
  },
  {
    "path": "app/layout.tsx",
    "chars": 192,
    "preview": "import \"styles/tailwind.css\"\n\nexport default function RootLayout({ children }: { children: React.ReactNode }) {\n  return"
  },
  {
    "path": "app/page.tsx",
    "chars": 2710,
    "preview": "import { Metadata } from \"next\"\nimport { Button } from \"components/Button/Button\"\n\nimport { LP_GRID_ITEMS } from \"lp-ite"
  },
  {
    "path": "components/Button/Button.stories.tsx",
    "chars": 603,
    "preview": "import type { Meta, StoryObj } from \"@storybook/react\"\nimport { Button } from \"./Button\"\n\nconst meta: Meta<typeof Button"
  },
  {
    "path": "components/Button/Button.test.tsx",
    "chars": 921,
    "preview": "import { render, screen } from \"@testing-library/react\"\nimport { describe, expect, it } from \"vitest\"\nimport { Button } "
  },
  {
    "path": "components/Button/Button.tsx",
    "chars": 1244,
    "preview": "import { cva, type VariantProps } from \"class-variance-authority\"\n\nimport { twMerge } from \"tailwind-merge\"\n\nconst butto"
  },
  {
    "path": "components/Tooltip/Tooltip.tsx",
    "chars": 1828,
    "preview": "\"use client\"\n\nimport * as RadixTooltip from \"@radix-ui/react-tooltip\"\nimport { cva, type VariantProps } from \"class-vari"
  },
  {
    "path": "e2e/example.spec.ts",
    "chars": 184,
    "preview": "import { expect, test } from \"@playwright/test\"\n\ntest(\"has title\", async ({ page }) => {\n  await page.goto(\"./\")\n\n  awai"
  },
  {
    "path": "env.mjs",
    "chars": 303,
    "preview": "import { createEnv } from \"@t3-oss/env-nextjs\"\nimport { z } from \"zod\"\n\nexport const env = createEnv({\n  server: {\n    A"
  },
  {
    "path": "eslint.config.mjs",
    "chars": 2754,
    "preview": "import * as fs from \"fs\"\n\n// https://github.com/francoismassart/eslint-plugin-tailwindcss/pull/381\n// import eslintPlugi"
  },
  {
    "path": "git-conventional-commits.yaml",
    "chars": 901,
    "preview": "---\nconvention:\n  commitTypes:\n  - feat\n  - fix\n  - perf\n  - refactor\n  - style\n  - test\n  - build\n  - ops\n  - docs\n  - "
  },
  {
    "path": "instrumentation.ts",
    "chars": 103,
    "preview": "import { registerOTel } from \"@vercel/otel\"\n\nexport function register() {\n  registerOTel(\"next-app\")\n}\n"
  },
  {
    "path": "lp-items.tsx",
    "chars": 15012,
    "preview": "export const LP_GRID_ITEMS = [\n  {\n    title: \"Next.js\",\n    description: \"Fast by default, with config optimized for pe"
  },
  {
    "path": "next-env.d.ts",
    "chars": 211,
    "preview": "/// <reference types=\"next\" />\n/// <reference types=\"next/image-types/global\" />\n\n// NOTE: This file should not be edite"
  },
  {
    "path": "next.config.ts",
    "chars": 592,
    "preview": "import withBundleAnalyzer from \"@next/bundle-analyzer\"\nimport { type NextConfig } from \"next\"\n\nimport { env } from \"./en"
  },
  {
    "path": "package.json",
    "chars": 4904,
    "preview": "{\n  \"name\": \"next-enterprise\",\n  \"version\": \"0.0.0\",\n  \"private\": true,\n  \"scripts\": {\n    \"dev\": \"cross-env FORCE_COLOR"
  },
  {
    "path": "playwright.config.ts",
    "chars": 2060,
    "preview": "import { defineConfig, devices } from \"@playwright/test\"\n\n/**\n * Read environment variables from file.\n * https://github"
  },
  {
    "path": "postcss.config.js",
    "chars": 97,
    "preview": "module.exports = {\n  plugins: {\n    \"postcss-import\": {},\n    \"@tailwindcss/postcss\": {},\n  },\n}\n"
  },
  {
    "path": "prettier.config.js",
    "chars": 138,
    "preview": "module.exports = {\n  plugins: [\"prettier-plugin-tailwindcss\"],\n  trailingComma: \"es5\",\n  tabWidth: 2,\n  printWidth: 120,"
  },
  {
    "path": "renovate.json",
    "chars": 290,
    "preview": "{\n  \"$schema\": \"https://docs.renovatebot.com/renovate-schema.json\",\n  \"extends\": [\n    \"config:base\"\n  ],\n  \"packageRule"
  },
  {
    "path": "report-bundle-size.js",
    "chars": 4003,
    "preview": "#!/usr/bin/env node\n/* eslint-disable no-console */\n/**\n * Copyright (c) HashiCorp, Inc.\n * SPDX-License-Identifier: MPL"
  },
  {
    "path": "reset.d.ts",
    "chars": 73,
    "preview": "import \"@total-typescript/ts-reset\"\nimport \"typed-query-selector/strict\"\n"
  },
  {
    "path": "styles/tailwind.css",
    "chars": 514,
    "preview": "@import 'tailwindcss';\n\n/*\n  The default border color has changed to `currentColor` in Tailwind CSS v4,\n  so we've added"
  },
  {
    "path": "tsconfig.json",
    "chars": 854,
    "preview": "{\n  \"$schema\": \"https://json.schemastore.org/tsconfig\",\n  \"display\": \"Next.js\",\n  \"compilerOptions\": {\n    \"target\": \"es"
  },
  {
    "path": "vercel.json",
    "chars": 112,
    "preview": "{\n  \"$schema\": \"https://openapi.vercel.sh/vercel.json\",\n  \"installCommand\": \"corepack enable && pnpm install\"\n}\n"
  },
  {
    "path": "vitest.config.ts",
    "chars": 439,
    "preview": "import { defineConfig } from \"vitest/config\"\nimport react from \"@vitejs/plugin-react\"\nimport tsconfigPaths from \"vite-ts"
  },
  {
    "path": "vitest.setup.ts",
    "chars": 35,
    "preview": "import \"@testing-library/jest-dom\"\n"
  }
]

About this extraction

This page contains the full source code of the Blazity/next-enterprise GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 41 files (56.6 KB), approximately 18.8k tokens, and a symbol index with 16 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!