Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
zbeyens committed Nov 20, 2024
1 parent b671a27 commit 636381f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
11 changes: 8 additions & 3 deletions apps/www/content/docs/media.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -129,9 +129,14 @@ There are two ways to implement file uploads in your editor:

#### UploadThing

1. Install [MediaPlaceholderElement](/docs/components/media-placeholder-element)
2. Get your secret key from [UploadThing](https://uploadthing.com/dashboard/settings) for free
3. Add your UploadThing secret key to `.env`:
1. Add [MediaPlaceholderElement](/docs/components/media-placeholder-element) component

2. Add API routes for UploadThing:

<ComponentInstallation name="api-uploadthing" inline />

3. Get your secret key from [UploadThing](https://uploadthing.com/dashboard/settings) for free
4. Add your UploadThing secret key to `.env`:

```bash title=".env"
UPLOADTHING_TOKEN=sk_live_xxx
Expand Down
4 changes: 3 additions & 1 deletion apps/www/src/components/component-installation.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ interface ComponentInstallationProps {
dependencies?: string[];
examples?: RegistryEntry[];
files?: any[];
inline?: boolean;
name?: string;
usage?: string[];
}
Expand All @@ -33,6 +34,7 @@ export function ComponentInstallation({
__previewFiles__ = '[]',
codeTabs,
examples,
inline,
name,
usage,
...props
Expand Down Expand Up @@ -112,7 +114,7 @@ export function ComponentInstallation({

return (
<div className="my-4">
<H2>Installation</H2>
{!inline && <H2>Installation</H2>}

<Tabs className="relative mt-6 w-full" defaultValue="cli">
<TabsList className="w-full justify-start rounded-none border-b bg-transparent p-0">
Expand Down

0 comments on commit 636381f

Please sign in to comment.