Skip to content

Commit 7229a0d

Browse files
authored
Add files page (#1267)
* move static assets info to new page * add new page to nav * edit and add file size limits
1 parent bad6762 commit 7229a0d

File tree

3 files changed

+30
-2
lines changed

3 files changed

+30
-2
lines changed

components/files.mdx

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
---
2+
title: "Files"
3+
description: "Serve static assets from your documentation"
4+
icon: "folder"
5+
---
6+
7+
Mintlify automatically serves static assets from your documentation repository at the appropriate path on your domain. For example, if you have `/images/my-logo.png` in your repo, the image file is available at `https://docs.your-project.com/images/my-logo.png`.
8+
9+
This works for any file type you want to make available to your users, including images, PDFs, videos, or schemas.
10+
11+
Files must be less than 20 MB for images and 100 MB for other file types.
12+
13+
## File organization
14+
15+
Organize your files using folders to keep your repository easy to navigate:
16+
17+
```text
18+
/your-project
19+
|- docs.json
20+
|- images/
21+
|- logo.png
22+
|- screenshots/
23+
|- dashboard.png
24+
|- assets/
25+
|- whitepaper.pdf
26+
|- demo-video.mp4
27+
```
28+
29+
Files are served from the root of your domain, so the structure in your repository directly maps to the URL structure. From the previous example, `assets/whitepaper.pdf` would be available at `https://docs.your-project.com/assets/whitepaper.pdf`.

docs.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@
6666
"pages": [
6767
"text",
6868
"image-embeds",
69+
"components/files",
6970
"list-table",
7071
"code",
7172
"reusable-snippets",

image-embeds.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,6 @@ icon: "image"
66

77
Add images, embed videos, and include interactive content with iframes to your documentation.
88

9-
All static assets in your docs repository are automatically served at the appropriate path on your domain. For example, if you have `/images/my-logo.png` in your repo, the image will be available at `https://docs.yoursite.com/images/my-logo.png`.
10-
119
<Frame>
1210
<img
1311
className="rounded-xl"

0 commit comments

Comments
 (0)