From 5013835f51665ae5f5808389b53903746b06629a Mon Sep 17 00:00:00 2001 From: Pavel Horal Date: Sat, 17 Jun 2023 21:28:37 +0200 Subject: [PATCH] docs: fix typo in dynamic routing example (#2515) --- docs/guide/routing.md | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/docs/guide/routing.md b/docs/guide/routing.md index c0821ecc..89b6003f 100644 --- a/docs/guide/routing.md +++ b/docs/guide/routing.md @@ -327,17 +327,15 @@ Instead, you can pass such content to each page using the `content` property on ```js export default { - paths() { - async paths() { - const posts = await (await fetch('https://my-cms.com/blog-posts')).json() + async paths() { + const posts = await (await fetch('https://my-cms.com/blog-posts')).json() - return posts.map((post) => { - return { - params: { id: post.id }, - content: post.content // raw Markdown or HTML - } - }) - } + return posts.map((post) => { + return { + params: { id: post.id }, + content: post.content // raw Markdown or HTML + } + }) } } ```