Skip to content

Commit 75c0dfa

Browse files
authored
Merge pull request #2405 from hey-api/docs/seo-2
docs: SEO improvements
2 parents e1d8a56 + 18a08e2 commit 75c0dfa

File tree

17 files changed

+539
-190
lines changed

17 files changed

+539
-190
lines changed

docs/.vitepress/theme/custom.css

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -404,3 +404,8 @@ a.migration:focus {
404404
background-color: var(--vp-sidebar-bg-color);
405405
}
406406
}
407+
408+
footer.VPDocFooter > .edit-info > .last-updated {
409+
/* don't render last updated date */
410+
display: none;
411+
}

docs/openapi-ts/clients/axios.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ client.setConfig({
238238

239239
You can use any of the approaches mentioned in [Configuration](#configuration), depending on how granular you want your custom instance to be.
240240

241-
## Config API
241+
## API
242242

243243
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/plugins/@hey-api/client-axios/types.d.ts) interface.
244244

docs/openapi-ts/clients/fetch.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ client.setConfig({
295295

296296
You can use any of the approaches mentioned in [Configuration](#configuration), depending on how granular you want your custom method to be.
297297

298-
## Config API
298+
## API
299299

300300
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/plugins/@hey-api/client-fetch/types.d.ts) interface.
301301

docs/openapi-ts/clients/next-js.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ client.setConfig({
282282

283283
You can use any of the approaches mentioned in [Configuration](#configuration), depending on how granular you want your custom method to be.
284284

285-
## Config API
285+
## API
286286

287287
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/plugins/@hey-api/client-next/types.d.ts) interface.
288288

docs/openapi-ts/clients/nuxt.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ client.setConfig({
251251

252252
You can use any of the approaches mentioned in [Configuration](#configuration), depending on how granular you want your custom method to be.
253253

254-
## Config API
254+
## API
255255

256256
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/plugins/@hey-api/client-nuxt/types.d.ts) interface.
257257

docs/openapi-ts/configuration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ Plugins are responsible for generating artifacts from your input. By default, He
155155

156156
You can learn more on the [Output](/openapi-ts/output) page.
157157

158-
## Config API
158+
## API
159159

160160
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/types/config.d.ts) interface.
161161

docs/openapi-ts/output.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,6 @@ import type { Pet } from './client/types.gen';
6060
If you're not importing artifacts from the index file, you can skip generating it altogether by setting the `output.indexFile` option to `false`.
6161

6262
```js
63-
import { defaultPlugins } from '@hey-api/openapi-ts';
64-
6563
export default {
6664
input: 'https://get.heyapi.dev/hey-api/backend',
6765
output: {
@@ -76,13 +74,11 @@ export default {
7674
You can choose which files should be re-exported by setting the `exportFromIndex` option to `true` on any plugin. For example, here's how you would re-export [Zod](/openapi-ts/plugins/zod) plugin exports.
7775

7876
```js
79-
import { defaultPlugins } from '@hey-api/openapi-ts';
80-
8177
export default {
8278
input: 'https://get.heyapi.dev/hey-api/backend',
8379
output: 'src/client',
8480
plugins: [
85-
...defaultPlugins,
81+
// ...other plugins
8682
{
8783
exportFromIndex: true, // [!code ++]
8884
name: 'zod',

docs/openapi-ts/output/json-schema.md

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,11 @@ You can modify the contents of `schemas.gen.ts` by configuring the `@hey-api/sch
1414
::: code-group
1515

1616
```js [json]
17-
import { defaultPlugins } from '@hey-api/openapi-ts';
18-
1917
export default {
2018
input: 'https://get.heyapi.dev/hey-api/backend',
2119
output: 'src/client',
2220
plugins: [
23-
...defaultPlugins,
21+
// ...other plugins
2422
{
2523
name: '@hey-api/schemas',
2624
type: 'json', // [!code ++]
@@ -30,13 +28,11 @@ export default {
3028
```
3129

3230
```js [form]
33-
import { defaultPlugins } from '@hey-api/openapi-ts';
34-
3531
export default {
3632
input: 'https://get.heyapi.dev/hey-api/backend',
3733
output: 'src/client',
3834
plugins: [
39-
...defaultPlugins,
35+
// ...other plugins
4036
{
4137
name: '@hey-api/schemas',
4238
type: 'form', // [!code ++]
@@ -46,13 +42,11 @@ export default {
4642
```
4743

4844
```js [disabled]
49-
import { defaultPlugins } from '@hey-api/openapi-ts';
50-
5145
export default {
5246
input: 'https://get.heyapi.dev/hey-api/backend',
5347
output: 'src/client',
5448
plugins: [
55-
...defaultPlugins,
49+
// ...other plugins
5650
'@hey-api/schemas', // [!code --]
5751
],
5852
};
@@ -96,7 +90,7 @@ if (userInput.length > maxInputLength) {
9690
}
9791
```
9892

99-
## Config API
93+
## API
10094

10195
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/plugins/@hey-api/schemas/types.d.ts) interface.
10296

docs/openapi-ts/output/sdk.md

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,11 @@ You can modify the contents of `sdk.gen.ts` by configuring the `@hey-api/sdk` pl
2626
::: code-group
2727

2828
```js [flat]
29-
import { defaultPlugins } from '@hey-api/openapi-ts';
30-
3129
export default {
3230
input: 'https://get.heyapi.dev/hey-api/backend',
3331
output: 'src/client',
3432
plugins: [
35-
...defaultPlugins,
33+
// ...other plugins
3634
{
3735
asClass: false, // default // [!code ++]
3836
name: '@hey-api/sdk',
@@ -42,13 +40,11 @@ export default {
4240
```
4341

4442
```js [class]
45-
import { defaultPlugins } from '@hey-api/openapi-ts';
46-
4743
export default {
4844
input: 'https://get.heyapi.dev/hey-api/backend',
4945
output: 'src/client',
5046
plugins: [
51-
...defaultPlugins,
47+
// ...other plugins
5248
{
5349
asClass: true, // [!code ++]
5450
name: '@hey-api/sdk',
@@ -224,7 +220,7 @@ export default {
224220

225221
Learn more about available validators on the [Validators](/openapi-ts/validators) page.
226222

227-
## Config API
223+
## API
228224

229225
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/plugins/@hey-api/sdk/types.d.ts) interface.
230226

docs/openapi-ts/output/typescript.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ export default {
130130

131131
We recommend exporting enums as plain JavaScript objects. [TypeScript enums](https://www.typescriptlang.org/docs/handbook/enums.html) are not a type-level extension of JavaScript and pose [typing challenges](https://dev.to/ivanzm123/dont-use-enums-in-typescript-they-are-very-dangerous-57bh).
132132

133-
## Config API
133+
## API
134134

135135
You can view the complete list of options in the [UserConfig](https://github.com/hey-api/openapi-ts/blob/main/packages/openapi-ts/src/plugins/@hey-api/typescript/types.d.ts) interface.
136136

0 commit comments

Comments
 (0)