# Detailed Usage Table
URL: /docs/components/detailed-usage-table
The Detailed Usage Table component provides a comprehensive breakdown of resource consumption with columns for resource name, used amount, limit, and percentage utilization. The percentage field is now optional and will be automatically calculated if not provided.
***
title: Detailed Usage Table
description: The Detailed Usage Table component provides a comprehensive breakdown of resource consumption with columns for resource name, used amount, limit, and percentage utilization. The percentage field is now optional and will be automatically calculated if not provided.
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
```tsx title="src/components/detailed-usage-table-demo.tsx"
"use client";
import { DetailedUsageTable } from "@/components/billingsdk/detailed-usage-table";
export function DetailedUsageTableDemo() {
return (
);
}
```
## Installation
```bash
npx shadcn@latest add @billingsdk/detailed-usage-table
```
```bash
pnpm dlx shadcn@latest add @billingsdk/detailed-usage-table
```
```bash
yarn dlx shadcn@latest add @billingsdk/detailed-usage-table
```
```bash
bunx shadcn@latest add @billingsdk/detailed-usage-table
```
```bash
npx @billingsdk/cli add detailed-usage-table
```
```bash
pnpm dlx @billingsdk/cli add detailed-usage-table
```
```bash
yarn dlx @billingsdk/cli add detailed-usage-table
```
```bash
bunx @billingsdk/cli add detailed-usage-table
```
## Usage
```tsx
import { DetailedUsageTable } from '@/components/billingsdk/detailed-usage-table';
```
```tsx
;
```
## Props
| Prop | Type | Description |
| ----------- | ----------------- | ------------------------------------------------ |
| className | `string` | Additional CSS classes to apply to the component |
| title | `string` | Title for the usage table section |
| description | `string` | Description for the usage table section |
| resources | `UsageResource[]` | Array of resource usage data |
### UsageResource Object
| Property | Type | Description |
| ---------- | ------------------- | ---------------------------------------------------------------------- |
| name | `string` | Name of the resource |
| used | `number` | Amount of the resource used |
| limit | `number` | Total limit for the resource |
| percentage | `number` *optional* | Percentage of resource used (automatically calculated if not provided) |
| unit | `string` | Unit of measurement (optional) |
```tsx
```
### Credits
* Created by [@sapatmohit](https://github.com/sapatmohit)