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
Copy file name to clipboardExpand all lines: fern/products/docs/pages/getting-started/project-structure.mdx
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -53,6 +53,8 @@ The `pages` folder is organized into subfolders based on the sections of your do
53
53
54
54
The `assets` folder contains any images or videos used in your documentation. You can reference these assets in your MDX files using relative paths.
55
55
56
+
Hellooo this is deep!!
57
+
56
58
<CodeBlocktitle="fern/assets">
57
59
```bash
58
60
assets
@@ -166,11 +168,11 @@ title: Fern's Documentation
166
168
</AccordionGroup>
167
169
168
170
<Note>
169
-
If you're using Fern for both API Reference documentation and SDKs, you'll use both `docs.yml` (the Docs configuration file) and `generators.yml` ([the SDK configuration file](/sdks/overview/project-structure#generatorsyml)) to configure [how SDK code snippets appear](/docs/api-references/sdk-snippets) in your API reference documentation.
171
+
If you're using Fern for both API Reference documentation and SDKs, you'll use both `docs.yml` (the Docs configuration file) and `generators.yml` ([the SDK configuration file](/sdks/overview/project-structure#generatorsyml)) to configure [how SDK code snippets appear](/docs/api-references/sdk-snippets) in your API reference documentation.
170
172
171
173
If you're only using Fern for API Reference docs, not SDKs, your `generators.yml` should simply link to your spec:
172
174
173
-
```yaml title="generators.yml"
175
+
```yaml
174
176
api:
175
177
specs:
176
178
- openapi: ../openapi/openapi.json
@@ -189,6 +191,4 @@ The `fern.config.json` file specifies your organization name and the version of
Finally, navigate to the docs directory (where the `fern` folder is located) and execute the following command to generate your documentation:
55
55
56
56
```bash
57
57
fern generate --docs
58
58
```
59
59
</Accordion>
60
-
<Accordion title='Use the Fern CLI'>
61
-
If you prefer, you can use our CLI to create a new project. Install the CLI
62
-
by running
60
+
61
+
<Accordion title="Use the Fern CLI">
62
+
If you prefer, you can use our CLI to create a new project. Install the CLI by running
63
63
64
64
```bash
65
65
npm install -g fern-api
@@ -78,13 +78,13 @@ In this guide, we'll show you how to get started with Fern in under 5 minutes.
78
78
├─ docs.yml
79
79
└─ fern.config.json
80
80
```
81
+
81
82
Finally, navigate to the docs directory (where the `fern` folder is located) and execute the following command to generate your documentation:
82
83
83
84
```bash
84
85
fern generate --docs
85
86
```
86
87
</Accordion>
87
-
88
88
</AccordionGroup>
89
89
90
90
### Update your docs
@@ -95,9 +95,9 @@ In this guide, we'll show you how to get started with Fern in under 5 minutes.
95
95
</Note>
96
96
97
97
<AccordionGroup toc={true}>
98
-
<Accordion title='Add content' >
99
-
Add content with MDX files.
100
-
98
+
<Accordion title="Add content">
99
+
Add content with MDX files.
100
+
101
101
```markdown
102
102
---
103
103
title: "Page Title"
@@ -108,13 +108,12 @@ In this guide, we'll show you how to get started with Fern in under 5 minutes.
108
108
```
109
109
110
110
<Note title="Supported Syntax">
111
-
Fern supports [GitHub flavored Markdown (GFM)](https://github.github.com/gfm/) within MDX files, no plugin required.
111
+
Fern supports [GitHub flavored Markdown (GFM)](https://github.github.com/gfm/) within MDX files, no plugin required.
112
112
</Note>
113
113
114
-
In order for the Markdown page to show up, you'll need to reference them from your `docs.yml` file. You
115
-
can reference the Markdown page within a section or as a standalone page.
114
+
In order for the Markdown page to show up, you'll need to reference them from your `docs.yml` file. You can reference the Markdown page within a section or as a standalone page.
116
115
117
-
```yml
116
+
```
118
117
navigation:
119
118
- page: Hello World
120
119
path: docs/pages/hello-world.mdx
@@ -124,80 +123,80 @@ In this guide, we'll show you how to get started with Fern in under 5 minutes.
124
123
path: docs/pages/hello-world.mdx
125
124
```
126
125
</Accordion>
127
-
<Accordion title='Add an API Reference' >
126
+
127
+
<Accordiontitle="Add an API Reference">
128
128
Add an API Reference by adding an OpenAPI Specification to your project.
129
129
130
130
```bash
131
131
fern init --openapi /path/to/openapi.yml
132
132
```
133
133
134
-
This will create an `openapi.yml` file in your project. You can reference this file in your
135
-
`docs.yml`file by adding an api block.
134
+
This will create an `openapi.yml` file in your project. You can reference this file in your `docs.yml` file by adding an api block.
136
135
137
-
```yml
136
+
```
138
137
navigation:
139
138
- api: "API Reference"
140
139
```
141
140
</Accordion>
142
-
<Accordion title='Brand your docs'>
141
+
142
+
<Accordiontitle="Brand your docs">
143
143
All of the branding for your docs can be configured in the `docs.yml` file.
144
144
145
-
For example, to set the logos, colors, and fonts for your docs, you can
146
-
add the following to your `docs.yml` file:
145
+
For example, to set the logos, colors, and fonts for your docs, you can add the following to your `docs.yml` file:
147
146
148
147
<CodeBlocktitle="docs.yml">
149
-
```yml
150
-
colors:
151
-
accent-primary:
152
-
dark: "#f0c193"
153
-
light: "#af5f1b"
154
-
155
-
logo:
156
-
dark: docs/assets/logo-dark.svg
157
-
light: docs/assets/logo-light.svg
158
-
height: 40
159
-
href: https://buildwithfern.com/
160
-
161
-
favicon: docs/assets/favicon.svg
162
-
```
148
+
```yml
149
+
colors:
150
+
accent-primary:
151
+
dark: "#f0c193"
152
+
light: "#af5f1b"
153
+
154
+
logo:
155
+
dark: docs/assets/logo-dark.svg
156
+
light: docs/assets/logo-light.svg
157
+
height: 40
158
+
href: https://buildwithfern.com/
159
+
160
+
favicon: docs/assets/favicon.svg
161
+
```
163
162
</CodeBlock>
164
-
165
163
</Accordion>
166
-
167
164
</AccordionGroup>
168
-
165
+
169
166
### Preview your docs
167
+
170
168
<AccordionGroup toc={true}>
171
-
<Accordion title='Preview your docs locally'>
169
+
<Accordion title="Preview your docs locally">
172
170
You can preview your docs locally for testing purposes by following the instructions [here](/docs/preview-publish/previewing-changes-locally).
173
171
</Accordion>
174
-
<Accordion title='Preview your docs in a PR'>
172
+
173
+
<Accordion title="Preview your docs in a PR">
175
174
`PR previews` offer a way to preview changes from pull requests (PRs) before merging code to a production branch. Learn more [here](/docs/preview-publish/previewing-changes-in-a-pr).
176
175
</Accordion>
177
176
</AccordionGroup>
178
-
177
+
179
178
### Publish to production
180
179
181
180
<AccordionGroup toc={true}>
182
-
<Accordion title='Publishing your docs'>
181
+
<Accordion title="Publishing your docs">
183
182
When you are ready for your docs to be publicly accessible, you can publish them using the Fern CLI.
0 commit comments