You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<Step title="Add versioning to your products (optional)">
115
122
116
-
You can optionally add versions to a product. Versioned and unversioned products can live next to each other in your site. Each version of a single product has its own `yml` file.
123
+
<Note>If you provide both an `image` and an `icon`, the `image` will take precedence.</Note>
117
124
118
-
In the below example, Product A is **unversioned** and Product B is **versioned**:
125
+
</Step>
126
+
<Step title="Add versioning to your products (optional)">
119
127
120
-
<CodeBlock>
128
+
Products can be versioned or unversioned. For versioned products, organize version files in a subdirectory structure:
121
129
122
-
```bash {8, 10-17}
123
-
fern/
124
-
├─ fern.config.json
125
-
├─ generators.yml
126
-
├─ docs.yml
127
-
├─ pages/
128
-
├─ ...
129
-
└─ products/
130
-
├── product-a.yml # basic unversioned product
131
-
└── product-b/ # versioned product
132
-
├─ product-b.yml
130
+
```bash
131
+
fern/
132
+
└─ products/
133
+
└─ data-api/
134
+
├─ data-api.yml # Product config
133
135
└─ versions/
134
-
├─ latest/
135
-
│ ├─ latest.yml
136
-
│ └─ pages/...
137
-
└─ v2/
138
-
├─ v2.yml
139
-
└─ pages/...
140
-
```
141
-
</CodeBlock>
136
+
├─ v2/
137
+
│ ├─ v2.yml # v2 config
138
+
│ └─ pages/ # v2 content
139
+
└─ v1/
140
+
├─ v1.yml # v1 config
141
+
└─ pages/ # v1 content
142
+
```
142
143
143
-
The top-level `doc.yml` configuration for a Fern Docs website containing two products, one unversioned and one versioned, might look something like this:
0 commit comments