From bd9ac159e6be1f7afcf31edb2e2cf0d611f906ed Mon Sep 17 00:00:00 2001 From: Sarah Rainsberger Date: Fri, 27 Oct 2023 19:28:51 +0000 Subject: [PATCH] remove most ssr page link anchors --- old-translations/de/core-concepts/endpoints.mdx | 2 +- old-translations/de/guides/rss.mdx | 2 +- old-translations/fr/core-concepts/endpoints.mdx | 2 +- old-translations/fr/guides/rss.mdx | 2 +- src/content/docs/de/core-concepts/endpoints.mdx | 2 +- src/content/docs/de/guides/deploy.mdx | 2 +- src/content/docs/de/guides/rss.mdx | 2 +- src/content/docs/en/core-concepts/endpoints.mdx | 2 +- src/content/docs/en/guides/backend/google-firebase.mdx | 2 +- src/content/docs/en/guides/cms/contentful.mdx | 2 +- src/content/docs/en/guides/cms/keystatic.mdx | 2 +- src/content/docs/en/guides/cms/storyblok.mdx | 2 +- src/content/docs/en/guides/cms/strapi.mdx | 2 +- src/content/docs/en/guides/deploy.mdx | 2 +- src/content/docs/en/guides/imports.mdx | 2 +- src/content/docs/en/guides/integrations-guide/deno.mdx | 2 +- src/content/docs/en/guides/migrate-to-astro/from-gatsby.mdx | 2 +- src/content/docs/en/guides/rss.mdx | 2 +- src/content/docs/en/reference/adapter-reference.mdx | 2 +- src/content/docs/en/reference/errors/no-adapter-installed.mdx | 2 +- .../reference/errors/static-client-address-not-available.mdx | 2 +- .../en/reference/errors/static-redirect-not-available.mdx | 2 +- src/content/docs/es/core-concepts/endpoints.mdx | 2 +- src/content/docs/es/guides/backend/google-firebase.mdx | 2 +- src/content/docs/es/guides/cms/contentful.mdx | 2 +- src/content/docs/es/guides/cms/storyblok.mdx | 2 +- src/content/docs/es/guides/cms/strapi.mdx | 2 +- src/content/docs/es/guides/deploy.mdx | 2 +- src/content/docs/es/guides/imports.mdx | 2 +- src/content/docs/es/guides/integrations-guide/deno.mdx | 2 +- src/content/docs/es/guides/migrate-to-astro/from-gatsby.mdx | 2 +- src/content/docs/es/guides/rss.mdx | 2 +- src/content/docs/es/guides/upgrade-to/v2.mdx | 2 +- src/content/docs/es/reference/adapter-reference.mdx | 2 +- src/content/docs/es/reference/errors/no-adapter-installed.mdx | 2 +- .../reference/errors/static-client-address-not-available.mdx | 2 +- .../es/reference/errors/static-redirect-not-available.mdx | 2 +- src/content/docs/fr/core-concepts/endpoints.mdx | 2 +- src/content/docs/fr/guides/deploy.mdx | 2 +- src/content/docs/it/guides/backend/google-firebase.mdx | 2 +- src/content/docs/it/guides/upgrade-to/v2.mdx | 2 +- src/content/docs/ja/core-concepts/endpoints.mdx | 2 +- src/content/docs/ja/guides/cms/contentful.mdx | 2 +- src/content/docs/ja/guides/cms/storyblok.mdx | 2 +- src/content/docs/ja/guides/deploy.mdx | 2 +- src/content/docs/ja/guides/imports.mdx | 2 +- src/content/docs/ja/guides/rss.mdx | 2 +- src/content/docs/ja/guides/upgrade-to/v2.mdx | 2 +- .../reference/errors/static-client-address-not-available.mdx | 2 +- .../ja/reference/errors/static-redirect-not-available.mdx | 2 +- src/content/docs/ko/guides/upgrade-to/v2.mdx | 2 +- src/content/docs/pl/guides/upgrade-to/v2.mdx | 2 +- src/content/docs/pt-br/core-concepts/endpoints.mdx | 4 ++-- src/content/docs/pt-br/guides/deploy.mdx | 2 +- src/content/docs/pt-br/guides/imports.mdx | 2 +- src/content/docs/pt-br/guides/integrations-guide/deno.mdx | 2 +- src/content/docs/pt-br/guides/rss.mdx | 2 +- src/content/docs/pt-br/guides/upgrade-to/v2.mdx | 2 +- src/content/docs/pt-br/reference/adapter-reference.mdx | 2 +- .../docs/pt-br/reference/errors/no-adapter-installed.mdx | 2 +- .../reference/errors/static-client-address-not-available.mdx | 2 +- .../pt-br/reference/errors/static-redirect-not-available.mdx | 2 +- src/content/docs/ru/guides/deploy.mdx | 2 +- src/content/docs/zh-cn/core-concepts/endpoints.mdx | 2 +- src/content/docs/zh-cn/guides/backend/google-firebase.mdx | 2 +- src/content/docs/zh-cn/guides/cms/contentful.mdx | 2 +- src/content/docs/zh-cn/guides/cms/storyblok.mdx | 2 +- src/content/docs/zh-cn/guides/cms/strapi.mdx | 2 +- src/content/docs/zh-cn/guides/deploy.mdx | 2 +- src/content/docs/zh-cn/guides/imports.mdx | 2 +- src/content/docs/zh-cn/guides/integrations-guide/deno.mdx | 2 +- .../docs/zh-cn/guides/migrate-to-astro/from-gatsby.mdx | 2 +- src/content/docs/zh-cn/guides/rss.mdx | 2 +- src/content/docs/zh-cn/reference/adapter-reference.mdx | 2 +- .../docs/zh-cn/reference/errors/no-adapter-installed.mdx | 2 +- .../reference/errors/static-client-address-not-available.mdx | 2 +- .../zh-cn/reference/errors/static-redirect-not-available.mdx | 2 +- src/content/docs/zh-tw/guides/deploy.mdx | 2 +- 78 files changed, 79 insertions(+), 79 deletions(-) diff --git a/old-translations/de/core-concepts/endpoints.mdx b/old-translations/de/core-concepts/endpoints.mdx index 4f5eb0bc95267..add863ba258cc 100644 --- a/old-translations/de/core-concepts/endpoints.mdx +++ b/old-translations/de/core-concepts/endpoints.mdx @@ -100,7 +100,7 @@ Alles, was bei den Endpunkten für statische Dateien beschrieben wurde, kann auc Im Gegensatz zum `static`-Modus werden allerdings im `server`-Modus deine Endpunkte erst dann erzeugt, wenn eine Anfrage für sie empfangen wird. Dies ermöglicht den Zugriff auf neue Funktionen, die zum Erstellungszeitpunkt nicht verfügbar sind, und erlaubt es dir, API-Routen zu erstellen, die auf Anfragen warten und ihren Code zur Laufzeit in einer sicheren Server-Umgebung ausführen. :::note -Stelle sicher, dass du [SSR aktivierst](/de/guides/server-side-rendering/#ssr-in-deinem-projekt-aktivieren), bevor du diese Beispiele ausprobierst. +Stelle sicher, dass du [SSR aktivierst](/de/guides/server-side-rendering/), bevor du diese Beispiele ausprobierst. ::: Server-Endpunkte können auf `params` zugreifen, ohne `getStaticPaths` zu exportieren, und sie können ein [`Response`](https://developer.mozilla.org/en-US/docs/Web/API/Response)-Objekt zurückgeben, welches dir ermöglicht, Statuscodes und Header zu setzen: diff --git a/old-translations/de/guides/rss.mdx b/old-translations/de/guides/rss.mdx index de7b95d40e08b..1964ee6b6a959 100644 --- a/old-translations/de/guides/rss.mdx +++ b/old-translations/de/guides/rss.mdx @@ -7,7 +7,7 @@ Astro unterstützt die schnelle, automatische Generierung von RSS-Feeds für Blo ## Einrichten von `@astrojs/rss` -Das `@astrojs/rss`-Paket bietet Hilfsfunktionen zur Erzeugung von RSS-Feeds mithilfe von [API-Endpunkten](/de/core-concepts/astro-pages/#nicht-html-seiten). Dies ermöglicht _sowohl_ statische Feeds, die zum Erstellungszeitpunkt der Website generiert werden, als auch die On-Demand-Generierung bei Verwendung eines [SSR-Adapters](/de/guides/server-side-rendering/#ssr-in-deinem-projekt-aktivieren). +Das `@astrojs/rss`-Paket bietet Hilfsfunktionen zur Erzeugung von RSS-Feeds mithilfe von [API-Endpunkten](/de/core-concepts/astro-pages/#nicht-html-seiten). Dies ermöglicht _sowohl_ statische Feeds, die zum Erstellungszeitpunkt der Website generiert werden, als auch die On-Demand-Generierung bei Verwendung eines [SSR-Adapters](/de/guides/server-side-rendering/). Installiere zu Beginn `@astrojs/rss` mit deinem bevorzugten Paketmanager: diff --git a/old-translations/fr/core-concepts/endpoints.mdx b/old-translations/fr/core-concepts/endpoints.mdx index b5db647f00c0d..070800a711634 100644 --- a/old-translations/fr/core-concepts/endpoints.mdx +++ b/old-translations/fr/core-concepts/endpoints.mdx @@ -102,7 +102,7 @@ Tout ce qui est décrit dans la section des points de terminaison statiques peut Mais, à la différence du mode `static`, lorsque vous configurez le mode `server`, les points de terminaison seront construits à la demande. Ceci déverrouille de nouvelles fonctionnalités qui ne sont pas disponibles au moment de la compilation, et vous permet de construire des routes d'API qui écoutent les demandes et exécutent le code de manière sécurisée sur le serveur au moment de l'exécution. :::note -Soyez sûr d'avoir [activé le SSR](/fr/guides/server-side-rendering/#activation-du-mode-ssr-dans-votre-projet) avant d'essayer ces exemples. +Soyez sûr d'avoir [activé le SSR](/fr/guides/server-side-rendering/) avant d'essayer ces exemples. ::: Les points de terminaison serveur peuvent accéder aux `params` sans avoir à exporter `getStaticPaths`, et ils peuvent retourner un objet [`Response`](https://developer.mozilla.org/en-US/docs/Web/API/Response), permettant d'affecter des codes de statut et des en-têtes : diff --git a/old-translations/fr/guides/rss.mdx b/old-translations/fr/guides/rss.mdx index f2675796abf3c..b0480e7ad4097 100644 --- a/old-translations/fr/guides/rss.mdx +++ b/old-translations/fr/guides/rss.mdx @@ -11,7 +11,7 @@ Astro prend en charge la génération rapide et automatique de flux RSS pour les ## Mise en place d'`@astrojs/rss` -Le [package `@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) fournit des fonctions d'aide pour la génération de flux RSS en utilisant des ["API endpoints" (ou points d'arrêt API)](/fr/core-concepts/endpoints/#points-de-terminaison-statiques). Cela permet de débloquer à la fois les builds statiques _et_ la génération à la demande lors de l'utilisation d'un [adaptateur SSR](/fr/guides/server-side-rendering/#activation-du-mode-ssr-dans-votre-projet). +Le [package `@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) fournit des fonctions d'aide pour la génération de flux RSS en utilisant des ["API endpoints" (ou points d'arrêt API)](/fr/core-concepts/endpoints/#points-de-terminaison-statiques). Cela permet de débloquer à la fois les builds statiques _et_ la génération à la demande lors de l'utilisation d'un [adaptateur SSR](/fr/guides/server-side-rendering/). Pour commencer, installez `@astrojs/rss` en utilisant votre gestionnaire de Package préféré : diff --git a/src/content/docs/de/core-concepts/endpoints.mdx b/src/content/docs/de/core-concepts/endpoints.mdx index 608d54790e5ed..01dcf4feffc35 100644 --- a/src/content/docs/de/core-concepts/endpoints.mdx +++ b/src/content/docs/de/core-concepts/endpoints.mdx @@ -99,7 +99,7 @@ Im Gegensatz zum `static`-Modus werden die Endpunkte bei der Konfiguration des ` :::note -Stelle sicher, dass du [SSR aktivierst](/de/guides/server-side-rendering/#ssr-in-deinem-projekt-aktivieren), bevor du diese Beispiele ausprobierst. +Stelle sicher, dass du [SSR aktivierst](/de/guides/server-side-rendering/), bevor du diese Beispiele ausprobierst. ::: Server-Endpunkte können auf `params` zugreifen, ohne `getStaticPaths` zu exportieren, und sie können ein [`Response`](https://developer.mozilla.org/en-US/docs/Web/API/Response)-Objekt zurückgeben, welches dir ermöglicht, Statuscodes und Header zu setzen: diff --git a/src/content/docs/de/guides/deploy.mdx b/src/content/docs/de/guides/deploy.mdx index e21dcc2c4663a..fe3866cbacc5b 100644 --- a/src/content/docs/de/guides/deploy.mdx +++ b/src/content/docs/de/guides/deploy.mdx @@ -77,6 +77,6 @@ Die Build-Ausgabe wird standardmäßig ins Verzeichnis `dist/` geschrieben. Dies :::note Bevor du deine Website mit aktiviertem [SSR (serverseitigem Rendern)](/de/guides/server-side-rendering/) veröffentlichst, stelle bitte Folgendes sicher: - - Du hast den [geeigneten SSR-Adapter](/de/guides/server-side-rendering/#ssr-in-deinem-projekt-aktivieren) als Projektabhängigkeit installiert. + - Du hast den [geeigneten SSR-Adapter](/de/guides/server-side-rendering/) als Projektabhängigkeit installiert. - Du hast die [Konfiguration angepasst](/de/reference/configuration-reference/#integrations) und den Adapter zu den Imports sowie dem Standard-Export deiner `astro.config.mjs`-Datei hinzugefügt. ::: diff --git a/src/content/docs/de/guides/rss.mdx b/src/content/docs/de/guides/rss.mdx index 0b66575d6ccbd..6d61b2e5e4b0c 100644 --- a/src/content/docs/de/guides/rss.mdx +++ b/src/content/docs/de/guides/rss.mdx @@ -11,7 +11,7 @@ Astro unterstützt die schnelle, automatische Generierung von RSS-Feeds für Blo ## Einrichten von `@astrojs/rss` -Das `@astrojs/rss`-Paket bietet Hilfsfunktionen zur Erzeugung von RSS-Feeds mithilfe von [API-Endpunkten](/de/core-concepts/astro-pages/#nicht-html-seiten). Dies ermöglicht statische Feeds _und_ die On-Demand-Generierung bei Verwendung eines [SSR-Adapters](/de/guides/server-side-rendering/#ssr-in-deinem-projekt-aktivieren). +Das `@astrojs/rss`-Paket bietet Hilfsfunktionen zur Erzeugung von RSS-Feeds mithilfe von [API-Endpunkten](/de/core-concepts/astro-pages/#nicht-html-seiten). Dies ermöglicht statische Feeds _und_ die On-Demand-Generierung bei Verwendung eines [SSR-Adapters](/de/guides/server-side-rendering/). 1. Installiere `@astrojs/rss` mit deinem bevorzugten Paketmanager: diff --git a/src/content/docs/en/core-concepts/endpoints.mdx b/src/content/docs/en/core-concepts/endpoints.mdx index acd172d242bcb..2e885a85535a2 100644 --- a/src/content/docs/en/core-concepts/endpoints.mdx +++ b/src/content/docs/en/core-concepts/endpoints.mdx @@ -99,7 +99,7 @@ But, unlike in `static` mode, when you configure `server` mode, the endpoints wi :::note -Be sure to [enable SSR](/en/guides/server-side-rendering/#enabling-ssr-in-your-project) before trying these examples. +Be sure to [enable SSR](/en/guides/server-side-rendering/) before trying these examples. ::: Server endpoints can access `params` without exporting `getStaticPaths`, and they can return a [`Response`](https://developer.mozilla.org/en-US/docs/Web/API/Response) object, allowing you to set status codes and headers: diff --git a/src/content/docs/en/guides/backend/google-firebase.mdx b/src/content/docs/en/guides/backend/google-firebase.mdx index 33c9d6b505c1f..239f0fbe3429d 100644 --- a/src/content/docs/en/guides/backend/google-firebase.mdx +++ b/src/content/docs/en/guides/backend/google-firebase.mdx @@ -19,7 +19,7 @@ See our separate guide for [deploying to Firebase hosting](/en/guides/deploy/goo ### Prerequisites - A [Firebase project with a web app configured](https://firebase.google.com/docs/web/setup). -- An Astro project with [server-side rendering (SSR)](/en/guides/server-side-rendering/#enabling-ssr-in-your-project) enabled. +- An Astro project with [server-side rendering (SSR)](/en/guides/server-side-rendering/) enabled. - Firebase credentials: You will need two sets of credentials to connect Astro to Firebase: - Web app credentials: These credentials will be used by the client side of your app. You can find them in the Firebase console under *Project settings > General*. Scroll down to the **Your apps** section and click on the **Web app** icon. - Project credentials: These credentials will be used by the server side of your app. You can generate them in the Firebase console under *Project settings > Service accounts > Firebase Admin SDK > Generate new private key*. diff --git a/src/content/docs/en/guides/cms/contentful.mdx b/src/content/docs/en/guides/cms/contentful.mdx index 491f8c5b2058c..91e23847184b2 100644 --- a/src/content/docs/en/guides/cms/contentful.mdx +++ b/src/content/docs/en/guides/cms/contentful.mdx @@ -428,7 +428,7 @@ Navigate to http://localhost:4321/ and click on one of your posts to make sure y #### Server side rendering -If you've [opted in to SSR mode](/en/guides/server-side-rendering/#enabling-ssr-in-your-project), you will use a dynamic route that uses a `slug` parameter to fetch the data from Contentful. +If you've [opted in to SSR mode](/en/guides/server-side-rendering/), you will use a dynamic route that uses a `slug` parameter to fetch the data from Contentful. Create a `[slug].astro` page in `src/pages/posts`. Use [`Astro.params`](/en/reference/api-reference/#astroparams) to get the slug from the URL, then pass that to `getEntries`: diff --git a/src/content/docs/en/guides/cms/keystatic.mdx b/src/content/docs/en/guides/cms/keystatic.mdx index ceab6817dc87d..523bdecbf8f81 100644 --- a/src/content/docs/en/guides/cms/keystatic.mdx +++ b/src/content/docs/en/guides/cms/keystatic.mdx @@ -23,7 +23,7 @@ Select the Astro template, and you'll be ready to [deploy](#deploying-keystatic- ## Prerequisites -- An existing Astro project [with server-side rendering (SSR) and `output: 'hybrid'` configured](/en/guides/server-side-rendering/#enabling-ssr-in-your-project). +- An existing Astro project [with server-side rendering (SSR) and `output: 'hybrid'` configured](/en/guides/server-side-rendering/). :::note If you intend to sync Keystatic's data with GitHub, you will also need **a GitHub account with `write` permissions** on the repository for this project. diff --git a/src/content/docs/en/guides/cms/storyblok.mdx b/src/content/docs/en/guides/cms/storyblok.mdx index 4c67c7838fc4e..dbcf11ca3ae5f 100644 --- a/src/content/docs/en/guides/cms/storyblok.mdx +++ b/src/content/docs/en/guides/cms/storyblok.mdx @@ -451,7 +451,7 @@ When adding folders inside of Storyblok, include them in the slug when interacti #### Server-side rendering -If you’ve [opted into SSR mode](/en/guides/server-side-rendering/#enabling-ssr-in-your-project), you will use dynamic routes to fetch the page data from Storyblok. +If you’ve [opted into SSR mode](/en/guides/server-side-rendering/), you will use dynamic routes to fetch the page data from Storyblok. Create a new directory `src/pages/blog/` and add a new file called `[...slug].astro` with the following code: diff --git a/src/content/docs/en/guides/cms/strapi.mdx b/src/content/docs/en/guides/cms/strapi.mdx index 37e361287fd2a..d47aff2b3590f 100644 --- a/src/content/docs/en/guides/cms/strapi.mdx +++ b/src/content/docs/en/guides/cms/strapi.mdx @@ -318,7 +318,7 @@ Make sure to choose the right rendering for your content. For markdown check out #### Server-side rendering -If you've [opted into SSR mode](/en/guides/server-side-rendering/#enabling-ssr-in-your-project) with `output: server` or `output: hybrid`, [generate your dynamic routes](/en/core-concepts/routing/#server-ssr-mode) using the following code: +If you've [opted into SSR mode](/en/guides/server-side-rendering/) with `output: server` or `output: hybrid`, [generate your dynamic routes](/en/core-concepts/routing/#server-ssr-mode) using the following code: Create the `src/pages/blog/[slug].astro` file: diff --git a/src/content/docs/en/guides/deploy.mdx b/src/content/docs/en/guides/deploy.mdx index b646ebba30d7b..1882f64befca8 100644 --- a/src/content/docs/en/guides/deploy.mdx +++ b/src/content/docs/en/guides/deploy.mdx @@ -78,7 +78,7 @@ By default, the build output will be placed at `dist/`. This location can be cha :::note Before deploying your Astro site with [SSR (server-side rendering)](/en/guides/server-side-rendering/) enabled, make sure you have: -- Installed the [appropriate adapter](/en/guides/server-side-rendering/#enabling-ssr-in-your-project) to your project dependencies (either manually, or using the adapter's `astro add` command, e.g. `npx astro add netlify`). +- Installed the [appropriate adapter](/en/guides/server-side-rendering/) to your project dependencies (either manually, or using the adapter's `astro add` command, e.g. `npx astro add netlify`). - [Added the adapter](/en/reference/configuration-reference/#integrations) to your `astro.config.mjs` file's import and default export when installing manually. (The `astro add` command will take care of this step for you!) ::: diff --git a/src/content/docs/en/guides/imports.mdx b/src/content/docs/en/guides/imports.mdx index 6f8c73a758c3d..d2762f22d8a65 100644 --- a/src/content/docs/en/guides/imports.mdx +++ b/src/content/docs/en/guides/imports.mdx @@ -217,7 +217,7 @@ Astro supports loading WASM files directly into your application using the brows ## Node Builtins -We encourage Astro users to avoid Node.js builtins (`fs`, `path`, etc.) whenever possible. Astro is compatible with multiple runtimes using [adapters](/en/guides/server-side-rendering/#adding-an-adapter). This includes [Deno](https://github.com/denoland/deno-astro-adapter) and [Cloudflare Workers](/en/guides/integrations-guide/cloudflare/) which do not support Node builtin modules such as `fs`. +We encourage Astro users to avoid Node.js builtins (`fs`, `path`, etc.) whenever possible. Astro is compatible with multiple runtimes using [adapters](/en/guides/server-side-rendering/). This includes [Deno](https://github.com/denoland/deno-astro-adapter) and [Cloudflare Workers](/en/guides/integrations-guide/cloudflare/) which do not support Node builtin modules such as `fs`. Our aim is to provide Astro alternatives to common Node.js builtins. However, no such alternatives exist today. So, if you _really_ need to use these builtin modules we don't want to stop you. Astro supports Node.js builtins using Node’s newer `node:` prefix. If you want to read a file, for example, you can do so like this: diff --git a/src/content/docs/en/guides/integrations-guide/deno.mdx b/src/content/docs/en/guides/integrations-guide/deno.mdx index 84b786e7af0aa..4658062bee9c0 100644 --- a/src/content/docs/en/guides/integrations-guide/deno.mdx +++ b/src/content/docs/en/guides/integrations-guide/deno.mdx @@ -8,4 +8,4 @@ The Deno adapter allows Astro to deploy your SSR site to Deno targets including The Deno adapter was previously maintained by Astro but now is maintained by Deno directly. Usage is now documented [in the Deno adapter repository](https://github.com/denoland/deno-astro-adapter). -If you are currently using this Astro adapter, you will need to migrate to the new Deno version or to [add another adapter](/en/guides/server-side-rendering/#adding-an-adapter) to continue using SSR in your project. +If you are currently using this Astro adapter, you will need to migrate to the new Deno version or to [add another adapter](/en/guides/server-side-rendering/) to continue using SSR in your project. diff --git a/src/content/docs/en/guides/migrate-to-astro/from-gatsby.mdx b/src/content/docs/en/guides/migrate-to-astro/from-gatsby.mdx index dac29713f5be0..9aff9e1f371d2 100644 --- a/src/content/docs/en/guides/migrate-to-astro/from-gatsby.mdx +++ b/src/content/docs/en/guides/migrate-to-astro/from-gatsby.mdx @@ -239,7 +239,7 @@ Gatsby has several top-level configuration files that also include site and page - `gatsby-node.js`: You will not need to create your own nodes in Astro, but viewing the schema in this file may help you with defining types in your Astro project. -- `gatsby-ssr.js`: If you choose to use SSR in Astro, you will [add and configure the SSR adapter](/en/guides/server-side-rendering/#adding-an-adapter) of your choice directly in `astro.config.mjs`. +- `gatsby-ssr.js`: If you choose to use SSR in Astro, you will [add and configure the SSR adapter](/en/guides/server-side-rendering/) of your choice directly in `astro.config.mjs`. ## Reference: Convert to Astro Syntax diff --git a/src/content/docs/en/guides/rss.mdx b/src/content/docs/en/guides/rss.mdx index 09340fe1ddcbd..ce883f258231e 100644 --- a/src/content/docs/en/guides/rss.mdx +++ b/src/content/docs/en/guides/rss.mdx @@ -12,7 +12,7 @@ Astro supports fast, automatic RSS feed generation for blogs and other content w ## Setting up `@astrojs/rss` -The package [`@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) provides helpers for generating RSS feeds using [API endpoints](/en/core-concepts/endpoints/#static-file-endpoints). This unlocks both static builds _and_ on-demand generation when using an [SSR adapter](/en/guides/server-side-rendering/#adding-an-adapter). +The package [`@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) provides helpers for generating RSS feeds using [API endpoints](/en/core-concepts/endpoints/#static-file-endpoints). This unlocks both static builds _and_ on-demand generation when using an [SSR adapter](/en/guides/server-side-rendering/). 1. Install `@astrojs/rss` using your preferred package manager: diff --git a/src/content/docs/en/reference/adapter-reference.mdx b/src/content/docs/en/reference/adapter-reference.mdx index 68710b6a30047..957f300f4a97e 100644 --- a/src/content/docs/en/reference/adapter-reference.mdx +++ b/src/content/docs/en/reference/adapter-reference.mdx @@ -6,7 +6,7 @@ import Since from '~/components/Since.astro'; import FileTree from '~/components/FileTree.astro'; -Astro is designed to make it easy to deploy to any cloud provider for SSR (server-side rendering). This ability is provided by __adapters__, which are [integrations](/en/reference/integrations-reference/). See the [SSR guide](/en/guides/server-side-rendering/#adding-an-adapter) to learn how to use an existing adapter. +Astro is designed to make it easy to deploy to any cloud provider for SSR (server-side rendering). This ability is provided by __adapters__, which are [integrations](/en/reference/integrations-reference/). See the [SSR guide](/en/guides/server-side-rendering/) to learn how to use an existing adapter. ## What is an adapter diff --git a/src/content/docs/en/reference/errors/no-adapter-installed.mdx b/src/content/docs/en/reference/errors/no-adapter-installed.mdx index d51681d6eba50..0efd2a97e8776 100644 --- a/src/content/docs/en/reference/errors/no-adapter-installed.mdx +++ b/src/content/docs/en/reference/errors/no-adapter-installed.mdx @@ -20,6 +20,6 @@ To use server-side rendering, an adapter needs to be installed so Astro knows ho **See Also:** - [Server-side Rendering](/en/guides/server-side-rendering/) -- [Adding an Adapter](/en/guides/server-side-rendering/#adding-an-adapter) +- [Adding an Adapter](/en/guides/server-side-rendering/) diff --git a/src/content/docs/en/reference/errors/static-client-address-not-available.mdx b/src/content/docs/en/reference/errors/static-client-address-not-available.mdx index db0bb2c9da644..c265bf8f858b3 100644 --- a/src/content/docs/en/reference/errors/static-client-address-not-available.mdx +++ b/src/content/docs/en/reference/errors/static-client-address-not-available.mdx @@ -21,7 +21,7 @@ The `Astro.clientAddress` property is only available when [Server-side rendering To get the user's IP address in static mode, different APIs such as [Ipify](https://www.ipify.org/) can be used in a [Client-side script](/en/guides/client-side-scripts/) or it may be possible to get the user's IP using a serverless function hosted on your hosting provider. **See Also:** -- [Enabling SSR in Your Project](/en/guides/server-side-rendering/#enabling-ssr-in-your-project) +- [Enabling SSR in Your Project](/en/guides/server-side-rendering/) - [Astro.clientAddress](/en/reference/api-reference/#astroclientaddress) diff --git a/src/content/docs/en/reference/errors/static-redirect-not-available.mdx b/src/content/docs/en/reference/errors/static-redirect-not-available.mdx index 33cea00ba861d..f2e490db6d751 100644 --- a/src/content/docs/en/reference/errors/static-redirect-not-available.mdx +++ b/src/content/docs/en/reference/errors/static-redirect-not-available.mdx @@ -25,7 +25,7 @@ The `Astro.redirect` function is only available when [Server-side rendering](/en To redirect on a static website, the [meta refresh attribute](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta) can be used. Certain hosts also provide config-based redirects (ex: [Netlify redirects](https://docs.netlify.com/routing/redirects/)). **See Also:** -- [Enabling SSR in Your Project](/en/guides/server-side-rendering/#enabling-ssr-in-your-project) +- [Enabling SSR in Your Project](/en/guides/server-side-rendering/) - [Astro.redirect](/en/reference/api-reference/#astroredirect) diff --git a/src/content/docs/es/core-concepts/endpoints.mdx b/src/content/docs/es/core-concepts/endpoints.mdx index 274748a85f3ad..2c6334fded30e 100644 --- a/src/content/docs/es/core-concepts/endpoints.mdx +++ b/src/content/docs/es/core-concepts/endpoints.mdx @@ -98,7 +98,7 @@ Pero, a diferencia del modo `static`, cuando configuras el modo `server`, los en :::note -Asegúrate de [habilitar SSR](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto) antes de probar estos ejemplos. +Asegúrate de [habilitar SSR](/es/guides/server-side-rendering/) antes de probar estos ejemplos. ::: Los endpoints del servidor pueden acceder a `params` sin exportar `getStaticPaths`, y pueden retornar un objeto [`Response`](https://developer.mozilla.org/es/docs/Web/API/Response), lo que te permite establecer códigos de estado y encabezados: diff --git a/src/content/docs/es/guides/backend/google-firebase.mdx b/src/content/docs/es/guides/backend/google-firebase.mdx index ae8d475ac1392..e6ad8e55aacbf 100644 --- a/src/content/docs/es/guides/backend/google-firebase.mdx +++ b/src/content/docs/es/guides/backend/google-firebase.mdx @@ -19,7 +19,7 @@ Consulta nuestra guía independiente para [desplegar en Firebase Hosting](/es/gu ### Prerrequesitos - Un [proyecto de Firebase con una aplicación web configurada](https://firebase.google.com/docs/web/setup). -- Un proyecto de Astro con [renderizado del lado del servidor (SSR)](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto) habilitado. +- Un proyecto de Astro con [renderizado del lado del servidor (SSR)](/es/guides/server-side-rendering/) habilitado. - Credenciales de Firebase: Necesitarás dos conjuntos de credenciales para conectar Astro a Firebase: - Credenciales de la aplicación web: Estas credenciales serán utilizadas por el lado del cliente de tu aplicación. Puedes encontrarlas en la consola de Firebase en *Project settings > General*. Desplázate hacia abajo hasta la sección **Your apps** y haz clic en el icono de **Web app**. - Credenciales del proyecto: Estas credenciales serán utilizadas por el lado del servidor de tu aplicación. Puedes generarlas en la consola de Firebase en *Project settings > Service accounts > Firebase Admin SDK > Generate new private key*. diff --git a/src/content/docs/es/guides/cms/contentful.mdx b/src/content/docs/es/guides/cms/contentful.mdx index df91c735f5576..3ed64646fc453 100644 --- a/src/content/docs/es/guides/cms/contentful.mdx +++ b/src/content/docs/es/guides/cms/contentful.mdx @@ -430,7 +430,7 @@ Navega a http://localhost:4321/ y haz clic en uno de tus artículos para asegura #### Renderizado del lado del servidor -Si has [optado por el modo SSR](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto), usarás una ruta dinámica que usa un parámetro `slug` para obtener los datos de Contentful. +Si has [optado por el modo SSR](/es/guides/server-side-rendering/), usarás una ruta dinámica que usa un parámetro `slug` para obtener los datos de Contentful. Crea un archivo nuevo llamado `[slug].astro` en `src/pages/posts/`. Usa [`Astro.params`](/es/reference/api-reference/#astroparams) para obtener el slug de la URL, luego pásalo a `getEntries`: diff --git a/src/content/docs/es/guides/cms/storyblok.mdx b/src/content/docs/es/guides/cms/storyblok.mdx index 3d0e3471f660d..e8da0fa80206e 100644 --- a/src/content/docs/es/guides/cms/storyblok.mdx +++ b/src/content/docs/es/guides/cms/storyblok.mdx @@ -453,7 +453,7 @@ Cuando agregues carpetas dentro de Storyblok, inclúyelas en el slug al interact #### Renderizado en el lado del servidor -Si has [optado por el modo de SSR](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto), utilizarás rutas dinámicas para obtener los datos de la página desde Storyblok. +Si has [optado por el modo de SSR](/es/guides/server-side-rendering/), utilizarás rutas dinámicas para obtener los datos de la página desde Storyblok. Crea un nuevo directorio `src/pages/blog/` y agrega un nuevo archivo llamado `[...slug].astro` con el siguiente código: diff --git a/src/content/docs/es/guides/cms/strapi.mdx b/src/content/docs/es/guides/cms/strapi.mdx index dbca7045ab2b2..04171f194b7cf 100644 --- a/src/content/docs/es/guides/cms/strapi.mdx +++ b/src/content/docs/es/guides/cms/strapi.mdx @@ -318,7 +318,7 @@ Asegúrate de elegir el renderizado adecuado para tu contenido. Para Markdown, c #### Renderizado en el lado del servidor -Si has [optado por el modo SSR](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto) con `output: server` o `output: hybrid`, [genera tus rutas dinámicas](/es/core-concepts/routing/#modo-servidor-ssr) utilizando el siguiente código: +Si has [optado por el modo SSR](/es/guides/server-side-rendering/) con `output: server` o `output: hybrid`, [genera tus rutas dinámicas](/es/core-concepts/routing/#modo-servidor-ssr) utilizando el siguiente código: Crea el archivo `src/pages/blog/[slug].astro`: diff --git a/src/content/docs/es/guides/deploy.mdx b/src/content/docs/es/guides/deploy.mdx index bda8a1d5ada51..d8d054405f606 100644 --- a/src/content/docs/es/guides/deploy.mdx +++ b/src/content/docs/es/guides/deploy.mdx @@ -78,6 +78,6 @@ De forma predeterminada, el resultado de compilación se colocará en `dist/`. E :::note Antes de implementar tu proyecto de Astro con [SSR (renderizado en el servidor)](/es/guides/server-side-rendering/) habilitado, asegúrate de tener: -- Instalado el [adaptador apropiado](/es/guides/server-side-rendering/#añadiendo-un-adaptador) en tus dependencias (ya sea manualmente, o usando el comando `astro add`, p. ej. `npx astro add netlify`). +- Instalado el [adaptador apropiado](/es/guides/server-side-rendering/) en tus dependencias (ya sea manualmente, o usando el comando `astro add`, p. ej. `npx astro add netlify`). - [Agregado el adaptador](/es/reference/configuration-reference/#adapter) a tu *import* y *default export* en tu archivo `astro.config.mjs` cuando es instalado manualmente. (¡El comando `astro add` se hará cargo de este paso por ti!) ::: diff --git a/src/content/docs/es/guides/imports.mdx b/src/content/docs/es/guides/imports.mdx index c0dd4bc316a30..bae004f870d50 100644 --- a/src/content/docs/es/guides/imports.mdx +++ b/src/content/docs/es/guides/imports.mdx @@ -219,7 +219,7 @@ Astro es compatible con la carga de archivos WASM directamente en tu aplicación ## Módulos integrados de Node -Recomendamos a los usuarios de Astro que eviten usar los módulos integrados de Node.js (`fs`, `path`, etc.) siempre que sea posible. Astro es compatible con múltiples motores de ejecución usando [adaptadores](/es/guides/server-side-rendering/#añadiendo-un-adaptador). Esto incluye [Deno](https://github.com/denoland/deno-astro-adapter) y [Cloudflare Workers](/es/guides/integrations-guide/cloudflare/) que no son compatibles con los módulos integrados de Node como `fs`. +Recomendamos a los usuarios de Astro que eviten usar los módulos integrados de Node.js (`fs`, `path`, etc.) siempre que sea posible. Astro es compatible con múltiples motores de ejecución usando [adaptadores](/es/guides/server-side-rendering/). Esto incluye [Deno](https://github.com/denoland/deno-astro-adapter) y [Cloudflare Workers](/es/guides/integrations-guide/cloudflare/) que no son compatibles con los módulos integrados de Node como `fs`. El objetivo de Astro es proporcionar alternativas a los módulos integrados comunes de Node.js. Sin embargo, estas alternativas aún no existen. Si _realmente_ necesitas utilizar estos módulos, no queremos detenerlo. Astro es compatible con los módulos integrados de Node.js utilizando el nuevo prefijo `node:`. Si por ejemplo quieres leer un archivo, puedes hacerlo así: diff --git a/src/content/docs/es/guides/integrations-guide/deno.mdx b/src/content/docs/es/guides/integrations-guide/deno.mdx index 02030866fd8e2..0b1babbfd9b42 100644 --- a/src/content/docs/es/guides/integrations-guide/deno.mdx +++ b/src/content/docs/es/guides/integrations-guide/deno.mdx @@ -8,4 +8,4 @@ El adaptador Deno permite a Astro implementar tu sitio SSR en objetivos de Deno, Anteriormente, el adaptador Deno era mantenido por Astro, pero ahora es mantenido directamente por Deno. El uso ahora está documentado en el [repositorio del adaptador Deno](https://github.com/denoland/deno-astro-adapter). -Si actualmente estás utilizando este adaptador de Astro, deberás migrar a la nueva versión de Deno o [agregar otro adaptador](/es/guides/server-side-rendering/#añadiendo-un-adaptador) para seguir SSR en tu proyecto. +Si actualmente estás utilizando este adaptador de Astro, deberás migrar a la nueva versión de Deno o [agregar otro adaptador](/es/guides/server-side-rendering/) para seguir SSR en tu proyecto. diff --git a/src/content/docs/es/guides/migrate-to-astro/from-gatsby.mdx b/src/content/docs/es/guides/migrate-to-astro/from-gatsby.mdx index d75cd9048e5b0..cc51eece8117e 100644 --- a/src/content/docs/es/guides/migrate-to-astro/from-gatsby.mdx +++ b/src/content/docs/es/guides/migrate-to-astro/from-gatsby.mdx @@ -239,7 +239,7 @@ Gatsby tiene varios archivos de configuración de nivel superior que también in - `gatsby-node.js`: No necesitarás crear tus propios nodos en Astro, pero ver el esquema en este archivo puede ayudarte a definir tipos en tu proyecto de Astro. -- `gatsby-ssr.js`: Si decides utilizar SSR en Astro, deberás [añadir y configurar el adaptador SSR](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto) de tu elección directamente en `astro.config.mjs`. +- `gatsby-ssr.js`: Si decides utilizar SSR en Astro, deberás [añadir y configurar el adaptador SSR](/es/guides/server-side-rendering/) de tu elección directamente en `astro.config.mjs`. ## Referencia: Convertir a Sintaxis de Astro diff --git a/src/content/docs/es/guides/rss.mdx b/src/content/docs/es/guides/rss.mdx index a4bbe75d233b3..577134274c7c1 100644 --- a/src/content/docs/es/guides/rss.mdx +++ b/src/content/docs/es/guides/rss.mdx @@ -12,7 +12,7 @@ Astro proporciona una generación rápida y automática de RSS feeds para blogs ## Configurando `@astrojs/rss` -El paquete [`@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) provee helpers para generar RSS feeds utilizando [API endpoints](/es/core-concepts/endpoints/#endpoints-de-archivos-estáticos). Esto desbloquea la generación de RSS feeds para builds estáticos _y_ on-demand para cuando utilizamos un [adaptador SSR](/es/guides/server-side-rendering/#añadiendo-un-adaptador). +El paquete [`@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) provee helpers para generar RSS feeds utilizando [API endpoints](/es/core-concepts/endpoints/#endpoints-de-archivos-estáticos). Esto desbloquea la generación de RSS feeds para builds estáticos _y_ on-demand para cuando utilizamos un [adaptador SSR](/es/guides/server-side-rendering/). 1. instala `@astrojs/rss` utilizando tu gestor de paquetes favorito: diff --git a/src/content/docs/es/guides/upgrade-to/v2.mdx b/src/content/docs/es/guides/upgrade-to/v2.mdx index ec6a288729727..28d582a174407 100644 --- a/src/content/docs/es/guides/upgrade-to/v2.mdx +++ b/src/content/docs/es/guides/upgrade-to/v2.mdx @@ -413,7 +413,7 @@ export default defineConfig({ Estas características ahora están disponibles por defecto: - [Colecciones de Contenido](/es/guides/content-collections/) como una forma de administrar tus archivos Markdown y MDX con tipado. -- [Prerenderizado individual de páginas a HTML estático](/es/guides/server-side-rendering/#configuración-de-rutas-individuales) cuando se usa SSR para mejorar la velocidad y la caché. +- [Prerenderizado individual de páginas a HTML estático](/es/guides/server-side-rendering/) cuando se usa SSR para mejorar la velocidad y la caché. - Un overlay de mensajes de error rediseñado. ## Problemas Identificados diff --git a/src/content/docs/es/reference/adapter-reference.mdx b/src/content/docs/es/reference/adapter-reference.mdx index 049385d750f78..b2ed5875663bd 100644 --- a/src/content/docs/es/reference/adapter-reference.mdx +++ b/src/content/docs/es/reference/adapter-reference.mdx @@ -5,7 +5,7 @@ i18nReady: true import Since from '~/components/Since.astro'; import FileTree from '~/components/FileTree.astro'; -Astro está diseñado para que sea fácil de desplegar a cualquier proveedor de la nube que soporte SSR (server side rendering). Esta capacidad la proporcionan los __adaptadores__, que son [integraciones](/es/reference/integrations-reference/). Lee la [guía de SSR](/es/guides/server-side-rendering/#añadiendo-un-adaptador) para aprender cómo añadir un adaptador. +Astro está diseñado para que sea fácil de desplegar a cualquier proveedor de la nube que soporte SSR (server side rendering). Esta capacidad la proporcionan los __adaptadores__, que son [integraciones](/es/reference/integrations-reference/). Lee la [guía de SSR](/es/guides/server-side-rendering/) para aprender cómo añadir un adaptador. ## ¿Qué es un adaptador? diff --git a/src/content/docs/es/reference/errors/no-adapter-installed.mdx b/src/content/docs/es/reference/errors/no-adapter-installed.mdx index adaf02423963b..49ead03ac84b3 100644 --- a/src/content/docs/es/reference/errors/no-adapter-installed.mdx +++ b/src/content/docs/es/reference/errors/no-adapter-installed.mdx @@ -18,4 +18,4 @@ Para usar el renderizado en el servidor, se debe instalar un adaptador para que **Ver también:** - [Renderizado en el servidor](/es/guides/server-side-rendering/) -- [Adding an Adapter](/es/guides/server-side-rendering/#añadiendo-un-adaptador) +- [Adding an Adapter](/es/guides/server-side-rendering/) diff --git a/src/content/docs/es/reference/errors/static-client-address-not-available.mdx b/src/content/docs/es/reference/errors/static-client-address-not-available.mdx index 5ab53e34029ec..1c7ede2f21474 100644 --- a/src/content/docs/es/reference/errors/static-client-address-not-available.mdx +++ b/src/content/docs/es/reference/errors/static-client-address-not-available.mdx @@ -19,5 +19,5 @@ Para obtener la dirección IP del usuario en modo estático, se pueden usar dife **Ver también:** -- [Habilitando SSR en tu proyecto](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto) +- [Habilitando SSR en tu proyecto](/es/guides/server-side-rendering/) - [Astro.clientAddress](/es/reference/api-reference/#astroclientaddress) diff --git a/src/content/docs/es/reference/errors/static-redirect-not-available.mdx b/src/content/docs/es/reference/errors/static-redirect-not-available.mdx index e67a3c29710d4..807c33a3bb104 100644 --- a/src/content/docs/es/reference/errors/static-redirect-not-available.mdx +++ b/src/content/docs/es/reference/errors/static-redirect-not-available.mdx @@ -17,5 +17,5 @@ La función `Astro.redirect` solo está disponible cuando [el renderizado en el Para redirigir en un sitio web estático, se puede usar el [atributo meta de actualización](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/meta). Ciertos hosts también proporcionan redireccionamientos basados en configuración (por ejemplo, [redireccionamientos de Netlify](https://docs.netlify.com/routing/redirects/)). **Ver también:** -- [Habilitando SSR en tu proyecto](/es/guides/server-side-rendering/#habilitando-ssr-en-tu-proyecto) +- [Habilitando SSR en tu proyecto](/es/guides/server-side-rendering/) - [Astro.redirect](/es/reference/api-reference/#astroredirect) diff --git a/src/content/docs/fr/core-concepts/endpoints.mdx b/src/content/docs/fr/core-concepts/endpoints.mdx index 861eb4043249e..80a8a17d89ef5 100644 --- a/src/content/docs/fr/core-concepts/endpoints.mdx +++ b/src/content/docs/fr/core-concepts/endpoints.mdx @@ -99,7 +99,7 @@ Mais, contrairement au mode `static`, lorsque vous configurez le mode `server`, :::note -Veillez à [activer le SSR](/fr/guides/server-side-rendering/#enabling-ssr-in-your-project) avant d'essayer ces exemples. +Veillez à [activer le SSR](/fr/guides/server-side-rendering/) avant d'essayer ces exemples. ::: Les points de terminaison du serveur peuvent accéder à `params` sans exporter `getStaticPaths`, et ils peuvent retourner un objet [`Response`](https://developer.mozilla.org/fr-FR/docs/Web/API/Response), vous permettant de définir les codes d'état et les en-têtes : diff --git a/src/content/docs/fr/guides/deploy.mdx b/src/content/docs/fr/guides/deploy.mdx index 55028688b2246..c7c03f2a3098d 100644 --- a/src/content/docs/fr/guides/deploy.mdx +++ b/src/content/docs/fr/guides/deploy.mdx @@ -78,7 +78,7 @@ Par défaut, le dossier de build sera placé à `dist/`. Ce dossier peut être c :::note Avant de déployer votre site Astro avec du [SSR (server-side rendering)](/fr/guides/server-side-rendering/) activé, vérifiez que vous avez : -- Installé [l'adapteur approprié](/fr/guides/server-side-rendering/#enabling-ssr-in-your-project) en tant que dépendance de votre projet (que ça soit manuellement, ou en utilisant la commande de l'adapteur `astro add`, ex. `npx astro add netlify`). +- Installé [l'adapteur approprié](/fr/guides/server-side-rendering/) en tant que dépendance de votre projet (que ça soit manuellement, ou en utilisant la commande de l'adapteur `astro add`, ex. `npx astro add netlify`). - [Ajouté l'adapteur](/fr/reference/configuration-reference/#integrations) à votre fichier `astro.config.mjs` si vous installez manuellement. (La commande `astro add` fera cette étape automatiquement !) ::: diff --git a/src/content/docs/it/guides/backend/google-firebase.mdx b/src/content/docs/it/guides/backend/google-firebase.mdx index dd1149ad83cbd..eaec29617fa1f 100644 --- a/src/content/docs/it/guides/backend/google-firebase.mdx +++ b/src/content/docs/it/guides/backend/google-firebase.mdx @@ -18,7 +18,7 @@ Consulta la nostra guida separata per [il deployment su Firebase hosting](/it/gu ### Prerequisiti - Un [progetto Firebase con un'app web già configurata](https://firebase.google.com/docs/web/setup). -- Un progetto Astro con [server-side rendering (SSR)](/it/guides/server-side-rendering/#enabling-ssr-in-your-project) abilitato. +- Un progetto Astro con [server-side rendering (SSR)](/it/guides/server-side-rendering/) abilitato. - Credenziali Firebase: Avrai bisogno di due set di credenziali per collegare Astro a Firebase: - Credenziali dell'app web: Queste credenziali saranno utilizzate dal client della tua app. Puoi trovarle nella console di Firebase in *Impostazioni del progetto > Generali*. Scorri verso il basso fino alla sezione **Le tue app** e clicca sull'icona **App web**. - Credenziali del progetto: Queste credenziali saranno utilizzate dal server della tua app. Puoi generarle nella console di Firebase in *Impostazioni del progetto > Account di servizio > Firebase Admin SDK > Genera nuova chiave privata*. diff --git a/src/content/docs/it/guides/upgrade-to/v2.mdx b/src/content/docs/it/guides/upgrade-to/v2.mdx index 66e68ac1385d6..9ab89c81fea9e 100644 --- a/src/content/docs/it/guides/upgrade-to/v2.mdx +++ b/src/content/docs/it/guides/upgrade-to/v2.mdx @@ -415,7 +415,7 @@ export default defineConfig({ Queste funzionalità sono ora disponibili di default: - [Collezioni di Contenuti](/it/guides/content-collections/) come un modo per gestire i tuoi file Markdown e MDX con la sicurezza dei tipi di dati. -- [Prerendering delle pagine individuali in HTML statico](/it/guides/server-side-rendering/#configuring-individual-routes) quando si utilizza SSR (rendering lato server) per migliorare la velocità e il caching. +- [Prerendering delle pagine individuali in HTML statico](/it/guides/server-side-rendering/) quando si utilizza SSR (rendering lato server) per migliorare la velocità e il caching. - Un overlay dei messaggi di errore riprogettato. ## Problemi conosciuti diff --git a/src/content/docs/ja/core-concepts/endpoints.mdx b/src/content/docs/ja/core-concepts/endpoints.mdx index fab928823fe14..582fc03e5cd01 100644 --- a/src/content/docs/ja/core-concepts/endpoints.mdx +++ b/src/content/docs/ja/core-concepts/endpoints.mdx @@ -102,7 +102,7 @@ export const GET: APIRoute = ({ params, request }) => { :::note -これらの例を試す前に、必ず[SSRを有効](/ja/guides/server-side-rendering/#プロジェクトでssrを有効にする)にしてください。 +これらの例を試す前に、必ず[SSRを有効](/ja/guides/server-side-rendering/)にしてください。 ::: サーバーエンドポイントは、`getStaticPaths`のエクスポートなしで`params`にアクセスできます。また、[`Response`](https://developer.mozilla.org/ja/docs/Web/API/Response)オブジェクトを返せるので、ステータスコードやヘッダーを設定できます。 diff --git a/src/content/docs/ja/guides/cms/contentful.mdx b/src/content/docs/ja/guides/cms/contentful.mdx index 95256535666b4..3751e445bbce1 100644 --- a/src/content/docs/ja/guides/cms/contentful.mdx +++ b/src/content/docs/ja/guides/cms/contentful.mdx @@ -423,7 +423,7 @@ http://localhost:4321/posts/astro-is-amazing/にアクセスすると動的ル #### サーバーサイドレンダリング -[プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/#プロジェクトでssrを有効にする)場合、Contentfulデータを取得するために動的ルーティングで `slug` パラメータが利用されます。 +[プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/)場合、Contentfulデータを取得するために動的ルーティングで `slug` パラメータが利用されます。 `src/pages/posts`に`[slug].astro`を作成します。URLからスラッグを取得するために[`Astro.params`](/ja/reference/api-reference/#astroparams)を使って、以下のように`getEntries`に渡してあげます。 diff --git a/src/content/docs/ja/guides/cms/storyblok.mdx b/src/content/docs/ja/guides/cms/storyblok.mdx index cde7bfa1b04f0..7fac8563ceaec 100644 --- a/src/content/docs/ja/guides/cms/storyblok.mdx +++ b/src/content/docs/ja/guides/cms/storyblok.mdx @@ -413,7 +413,7 @@ const { content } = Astro.props #### サーバーサイドレンダリング -[プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/#プロジェクトでssrを有効にする)場合、Storyblokデータを取得するために動的ルーティングで `slug` パラメータが利用されます。 +[プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/)場合、Storyblokデータを取得するために動的ルーティングで `slug` パラメータが利用されます。 ```astro title="src/pages/[...slug].astro" --- diff --git a/src/content/docs/ja/guides/deploy.mdx b/src/content/docs/ja/guides/deploy.mdx index 5fa1eb94af015..db8eccb8d19d0 100644 --- a/src/content/docs/ja/guides/deploy.mdx +++ b/src/content/docs/ja/guides/deploy.mdx @@ -75,6 +75,6 @@ npm run build :::note [SSR(サーバーサイド・レンダリング)](/ja/guides/server-side-rendering/)を有効化してAstroサイトをデプロイする前に、確認してください: -- [適切なアダプター](/ja/guides/server-side-rendering/#プロジェクトでssrを有効にする)がプロジェクトの依存関係にインストールされていること(手動、またはアダプターの`astro add`コマンドを使用します。例: `npx astro add netlify`) +- [適切なアダプター](/ja/guides/server-side-rendering/)がプロジェクトの依存関係にインストールされていること(手動、またはアダプターの`astro add`コマンドを使用します。例: `npx astro add netlify`) - 手動インストール時に`astro.config.mjs`ファイルのimportとdefault exportに[アダプター](/ja/reference/configuration-reference/#インテグレーション)を追加していること(このステップは `astro add` コマンドが代行します!) ::: diff --git a/src/content/docs/ja/guides/imports.mdx b/src/content/docs/ja/guides/imports.mdx index 170707a11cf79..15bb271922d8c 100644 --- a/src/content/docs/ja/guides/imports.mdx +++ b/src/content/docs/ja/guides/imports.mdx @@ -228,7 +228,7 @@ Astroは、ブラウザの[`WebAssembly`](https://developer.mozilla.org/ja/docs/ ## Nodeビルトイン -Astroのユーザーには、可能な限りNode.jsのビルトイン(`fs`、`path`など)を避けることをおすすめします。Astroは、[アダプター](/ja/guides/server-side-rendering/#アダプターの追加)を使用して複数のランタイムと互換性があります。これには、`fs`などのNodeビルトインモジュールをサポートしない[Deno](https://github.com/denoland/deno-astro-adapter)や[Cloudflare Workers](/ja/guides/integrations-guide/cloudflare/)が含まれます。 +Astroのユーザーには、可能な限りNode.jsのビルトイン(`fs`、`path`など)を避けることをおすすめします。Astroは、[アダプター](/ja/guides/server-side-rendering/)を使用して複数のランタイムと互換性があります。これには、`fs`などのNodeビルトインモジュールをサポートしない[Deno](https://github.com/denoland/deno-astro-adapter)や[Cloudflare Workers](/ja/guides/integrations-guide/cloudflare/)が含まれます。 私たちの目的は、一般的なNode.jsのビルトインに対するAstroの代替機能を提供することです。しかし、今のところそのような代替機能は存在しません。ですから、もし本当にこれらのビルトインモジュールを使う必要があるのなら、それを止めたいとは思いません。AstroはNode.jsのビルトインを、Nodeの新しいプレフィックスである`node:`を使ってサポートしています。たとえば、ファイルを読み込む場合、次のようにします。 diff --git a/src/content/docs/ja/guides/rss.mdx b/src/content/docs/ja/guides/rss.mdx index 9996a548b4529..f9bba2b3e7b61 100644 --- a/src/content/docs/ja/guides/rss.mdx +++ b/src/content/docs/ja/guides/rss.mdx @@ -12,7 +12,7 @@ Astroはブログやその他のコンテンツウェブサイト向けに、RSS ## `@astrojs/rss`の準備 -`@astrojs/rss`パッケージは、[APIエンドポイント](/ja/core-concepts/endpoints/#静的ファイルのエンドポイント)を利用したRSS生成のヘルパーを提供します。静的ビルドと[SSRアダプター](/ja/guides/server-side-rendering/#アダプターの追加)を利用したオンデマンド生成の両方に対応しています。 +`@astrojs/rss`パッケージは、[APIエンドポイント](/ja/core-concepts/endpoints/#静的ファイルのエンドポイント)を利用したRSS生成のヘルパーを提供します。静的ビルドと[SSRアダプター](/ja/guides/server-side-rendering/)を利用したオンデマンド生成の両方に対応しています。 1. お好きなパッケージマネージャーで`@astrojs/rss`をインストールします。 diff --git a/src/content/docs/ja/guides/upgrade-to/v2.mdx b/src/content/docs/ja/guides/upgrade-to/v2.mdx index 03b6f37588042..16ab341ffad3d 100644 --- a/src/content/docs/ja/guides/upgrade-to/v2.mdx +++ b/src/content/docs/ja/guides/upgrade-to/v2.mdx @@ -416,7 +416,7 @@ export default defineConfig({ - MarkdownやMDXのファイルを型安全で管理する方法として、[コンテンツコレクション](/ja/guides/content-collections/)があります。 {/* TODO: Set anchor link from #機能 to #configuring-individual-routes */} -- SSR使用時に[個別ページ静的HTMLにプリレンダリング](/ja/guides/server-side-rendering/#機能)をし、高速化とキャッシュ性能の向上を図る。 +- SSR使用時に[個別ページ静的HTMLにプリレンダリング](/ja/guides/server-side-rendering/)をし、高速化とキャッシュ性能の向上を図る。 - エラーメッセージのオーバーレイのデザインを変更しました。 ## 既知の問題点 diff --git a/src/content/docs/ja/reference/errors/static-client-address-not-available.mdx b/src/content/docs/ja/reference/errors/static-client-address-not-available.mdx index c4a15c3ad2b56..8bf635f49fb59 100644 --- a/src/content/docs/ja/reference/errors/static-client-address-not-available.mdx +++ b/src/content/docs/ja/reference/errors/static-client-address-not-available.mdx @@ -13,7 +13,7 @@ githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/ 静的モードでユーザーのIPアドレスを取得するには、[クライアントサイドスクリプト](/ja/guides/client-side-scripts/)で[Ipify](https://www.ipify.org/)などの別のAPIを使用してください。あるいは、ホスティングプロバイダーのサーバーレス関数を使用してユーザーのIPを取得できる場合もあります。 **以下も参照してください:** -- [プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/#プロジェクトでssrを有効にする) +- [プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/) - [Astro.clientAddress](/ja/reference/api-reference/#astroclientaddress) diff --git a/src/content/docs/ja/reference/errors/static-redirect-not-available.mdx b/src/content/docs/ja/reference/errors/static-redirect-not-available.mdx index 11b55bd6536f9..84af6548943e5 100644 --- a/src/content/docs/ja/reference/errors/static-redirect-not-available.mdx +++ b/src/content/docs/ja/reference/errors/static-redirect-not-available.mdx @@ -17,5 +17,5 @@ githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/ 静的なウェブサイトでリダイレクトするには、[meta refresh属性](https://developer.mozilla.org/ja/docs/Web/HTML/Element/meta)を使用できます。また一部のホストは、設定ファイルによるリダイレクトを提供しています(たとえば[Netlifyのリダイレクト](https://docs.netlify.com/routing/redirects/))。 **以下も参照してください:** -- [プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/#プロジェクトでssrを有効にする) +- [プロジェクトでSSRを有効にする](/ja/guides/server-side-rendering/) - [Astro.redirect](/ja/reference/api-reference/#astroredirect) diff --git a/src/content/docs/ko/guides/upgrade-to/v2.mdx b/src/content/docs/ko/guides/upgrade-to/v2.mdx index 487f20ac01c59..b1b5bb0228532 100644 --- a/src/content/docs/ko/guides/upgrade-to/v2.mdx +++ b/src/content/docs/ko/guides/upgrade-to/v2.mdx @@ -411,7 +411,7 @@ export default defineConfig({ 다음 기능들이 이제 기본적으로 사용이 가능해졌습니다: - [Content Collections](/ko/guides/content-collections/)을 사용하여 Markdown과 MDX 파일을 타입 안전하게 관리할 수 있습니다. -- [Prerendering individual pages to static HTML](/ko/guides/server-side-rendering/#configuring-individual-routes)을 사용하여 속도와 캐시 가능성을 개선할 수 있습니다. +- [Prerendering individual pages to static HTML](/ko/guides/server-side-rendering/)을 사용하여 속도와 캐시 가능성을 개선할 수 있습니다. - 에러 메세지 오버레이의 디자인을 바꾸었습니다. ## 발견된 이슈 diff --git a/src/content/docs/pl/guides/upgrade-to/v2.mdx b/src/content/docs/pl/guides/upgrade-to/v2.mdx index cbc08663e6be8..922271244dc28 100644 --- a/src/content/docs/pl/guides/upgrade-to/v2.mdx +++ b/src/content/docs/pl/guides/upgrade-to/v2.mdx @@ -409,7 +409,7 @@ export default defineConfig({ Te funkcje są teraz domyślnie dostępne: - [Kolekcje Treści](/pl/guides/content-collections/) jako sposób na zarządzanie plikami Markdown i MDX z zabezpieczeniem typów. -- [Prerenderowanie pojedynczych stron do statycznego HTML](/pl/guides/server-side-rendering/#configuring-individual-routes) przy użyciu SSR w celu poprawy szybkości i możliwości cachowania. +- [Prerenderowanie pojedynczych stron do statycznego HTML](/pl/guides/server-side-rendering/) przy użyciu SSR w celu poprawy szybkości i możliwości cachowania. - Zmieniony wygląd nakładki z komunikatem o błędzie. ## Znane problemy diff --git a/src/content/docs/pt-br/core-concepts/endpoints.mdx b/src/content/docs/pt-br/core-concepts/endpoints.mdx index b53bd8682d3ce..b394fc980fdfe 100644 --- a/src/content/docs/pt-br/core-concepts/endpoints.mdx +++ b/src/content/docs/pt-br/core-concepts/endpoints.mdx @@ -7,7 +7,7 @@ import RecipeLinks from "~/components/RecipeLinks.astro"; O Astro permite que você crie endpoints customizados para servir e processar todo tipo de dados. Isso pode ser usado para gerar imagens, expor um arquivo RSS ou os usar como rotas de API para construir uma API completa para o seu site. -Em sites gerados de forma estática, seus endpoints customizados são chamados durante a fase de build para produzir arquivos estáticos. Já em sites usando o [modo SSR](/pt-br/guides/server-side-rendering/#habilitando-o-ssr-em-seu-projeto) seus endpoints customizados se tornarão endpoints reais executados a cada requisição. Endpoints estáticos e SSR são definidos de maneira similar, mas os endpoints SSR suportam funcionalidades adicionais. +Em sites gerados de forma estática, seus endpoints customizados são chamados durante a fase de build para produzir arquivos estáticos. Já em sites usando o [modo SSR](/pt-br/guides/server-side-rendering/) seus endpoints customizados se tornarão endpoints reais executados a cada requisição. Endpoints estáticos e SSR são definidos de maneira similar, mas os endpoints SSR suportam funcionalidades adicionais. ## Endpoints de Arquivos Estáticos @@ -99,7 +99,7 @@ Porém, diferente do modo `static`, quando você configura o modo `server`, os e :::note -Não se esqueça de [habilitar o modo SSR no seu projeto](/pt-br/guides/server-side-rendering/#habilitando-o-ssr-em-seu-projeto) antes de testar esses exemplos. +Não se esqueça de [habilitar o modo SSR no seu projeto](/pt-br/guides/server-side-rendering/) antes de testar esses exemplos. ::: Os endpoints do servidor tem acesso a propriedade `params` sem exportar a função `getStaticPaths` e podem retornar um objeto [`Response`](https://developer.mozilla.org/pt-BR/docs/Web/API/Response), permitindo que você defina códigos de status e cabeçalhos HTTP. diff --git a/src/content/docs/pt-br/guides/deploy.mdx b/src/content/docs/pt-br/guides/deploy.mdx index 6ce73180b5110..c6bf72ee6329c 100644 --- a/src/content/docs/pt-br/guides/deploy.mdx +++ b/src/content/docs/pt-br/guides/deploy.mdx @@ -77,7 +77,7 @@ Por padrão, o resultado da build será colocado em `dist/`. Este local pode ser :::note Antes de fazer deploy do seu site Astro com [SSR (renderização no lado do servidor)](/pt-br/guides/server-side-rendering/) ativado, certifique-se de que você: - - Instalou o [adaptador correto](/pt-br/guides/server-side-rendering/#adicionando-um-adaptador) nas dependências do seu projeto (seja manualmente ou utilizando o comando `astro add` do adaptador, e.x. `npx astro add netlify`). + - Instalou o [adaptador correto](/pt-br/guides/server-side-rendering/) nas dependências do seu projeto (seja manualmente ou utilizando o comando `astro add` do adaptador, e.x. `npx astro add netlify`). - [Adicionou o adaptador](/pt-br/reference/configuration-reference/#adapter) na importação e exportação padrão do seu arquivo `astro.config.mjs` ao instalar manualmente. (O comando `astro add` irá tomar conta dessa etapa por você!) ::: diff --git a/src/content/docs/pt-br/guides/imports.mdx b/src/content/docs/pt-br/guides/imports.mdx index f51fdc080c00b..27ffcb6f2be8e 100644 --- a/src/content/docs/pt-br/guides/imports.mdx +++ b/src/content/docs/pt-br/guides/imports.mdx @@ -218,7 +218,7 @@ Astro suporta o carregamento de arquivos WASM (Web Assembly) diretamente na sua ## Módulos Node Nativos -Nós recomendamos aos usuários do Astro que evitem o uso de módulos nativos do Node.js (`fs`, `path` e etc) sempre que possível. Astro é compatível com múltiplos motores usando [adaptadores](/pt-br/guides/server-side-rendering/#adicionando-um-adaptador). Isto inclui o [Deno](https://github.com/denoland/deno-astro-adapter) e o [Cloudflare Workers](/pt-br/guides/integrations-guide/cloudflare/) que não possuem suporte aos módulos integrados do Node como o `fs`. +Nós recomendamos aos usuários do Astro que evitem o uso de módulos nativos do Node.js (`fs`, `path` e etc) sempre que possível. Astro é compatível com múltiplos motores usando [adaptadores](/pt-br/guides/server-side-rendering/). Isto inclui o [Deno](https://github.com/denoland/deno-astro-adapter) e o [Cloudflare Workers](/pt-br/guides/integrations-guide/cloudflare/) que não possuem suporte aos módulos integrados do Node como o `fs`. Nossa missão é prover alternativas Astro para os módulos Node.js mais comuns. Entretanto, isto estas alternativas ainda não existem hoje. Então, se você _realmente_ precisa utilizar estes módulos, nós não queremos o impedir. Astro suporta os módulos Node.js usando o novo prefixo `node:` do Node. Se você precisa ler um arquivo, por exemplo, você pode fazer assim: diff --git a/src/content/docs/pt-br/guides/integrations-guide/deno.mdx b/src/content/docs/pt-br/guides/integrations-guide/deno.mdx index 1dc49ec4bbb0d..86fd361b64d2a 100644 --- a/src/content/docs/pt-br/guides/integrations-guide/deno.mdx +++ b/src/content/docs/pt-br/guides/integrations-guide/deno.mdx @@ -10,4 +10,4 @@ O adaptador Deno permite o Astro fazer o deploy do seu site SSR para um serviço O adaptador Deno anteriormente era mantido pelo time do Astro, mas agora é mantido pela própria equipe do Deno. O seu uso está documentado no [repositório do adaptador Deno](https://github.com/denoland/deno-astro-adapter). -Se você atualmente esta usando esse adaptador Astro você irá precisar migrar para a nova versão do Deno ou [para outro adaptador](/pt-br/guides/server-side-rendering/#adicionando-um-adaptador) para continuar usando SSR em seu projeto. +Se você atualmente esta usando esse adaptador Astro você irá precisar migrar para a nova versão do Deno ou [para outro adaptador](/pt-br/guides/server-side-rendering/) para continuar usando SSR em seu projeto. diff --git a/src/content/docs/pt-br/guides/rss.mdx b/src/content/docs/pt-br/guides/rss.mdx index ce36f06d90e81..03b10120bc6ea 100644 --- a/src/content/docs/pt-br/guides/rss.mdx +++ b/src/content/docs/pt-br/guides/rss.mdx @@ -12,7 +12,7 @@ Astro suporta geração rápida e automática de feeds RSS para blogs e outros w ## Configurando `@astrojs/rss` -O pacote [`@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) fornece utilitários para a geração de feeds RSS utilizando [endpoints de API](/pt-br/core-concepts/endpoints/#endpoints-de-arquivos-estáticos). Isso permite builds estáticas *e* geração sob demanda quando você estiver utilizando um [adaptador de SSR](/pt-br/guides/server-side-rendering/#adicionando-um-adaptador). +O pacote [`@astrojs/rss`](https://github.com/withastro/astro/tree/main/packages/astro-rss) fornece utilitários para a geração de feeds RSS utilizando [endpoints de API](/pt-br/core-concepts/endpoints/#endpoints-de-arquivos-estáticos). Isso permite builds estáticas *e* geração sob demanda quando você estiver utilizando um [adaptador de SSR](/pt-br/guides/server-side-rendering/). 1. Instale `@astrojs/rss` utilizando seu gerenciador de pacotes favorito: diff --git a/src/content/docs/pt-br/guides/upgrade-to/v2.mdx b/src/content/docs/pt-br/guides/upgrade-to/v2.mdx index 4bfc31ebf9eef..4abd0914e4937 100644 --- a/src/content/docs/pt-br/guides/upgrade-to/v2.mdx +++ b/src/content/docs/pt-br/guides/upgrade-to/v2.mdx @@ -415,7 +415,7 @@ export default defineConfig({ Essas funcionalidades agora estão disponíveis por padrão: - [Coleções de conteúdo](/pt-br/guides/content-collections/) como uma forma de gerenciar seus arquivos Markdown e MDX com segurança de tipos. -- [Pré-renderizar páginas individuais para HTML estático](/pt-br/guides/server-side-rendering/#configurando-rotas-individuais) ao utilizar SSR para melhorar a velocidade e cacheabilidade. +- [Pré-renderizar páginas individuais para HTML estático](/pt-br/guides/server-side-rendering/) ao utilizar SSR para melhorar a velocidade e cacheabilidade. - Uma sobreposição de mensagens de error redesenhada. ## Problemas Conhecidos diff --git a/src/content/docs/pt-br/reference/adapter-reference.mdx b/src/content/docs/pt-br/reference/adapter-reference.mdx index 848275008bad7..a095a39a39f35 100644 --- a/src/content/docs/pt-br/reference/adapter-reference.mdx +++ b/src/content/docs/pt-br/reference/adapter-reference.mdx @@ -5,7 +5,7 @@ i18nReady: true import Since from '~/components/Since.astro'; import FileTree from '~/components/FileTree.astro'; -Astro foi projetado para ser fácil realizar deploy em qualquer provedor da nuvem para SSR (renderização no lado do servidor). Essa habilidade é providenciada por __adaptadores__, que são [integrações](/pt-br/reference/integrations-reference/). Veja o [guia de SSR](/pt-br/guides/server-side-rendering/#adicionando-um-adaptador) para aprender como utilizar um adaptador existente. +Astro foi projetado para ser fácil realizar deploy em qualquer provedor da nuvem para SSR (renderização no lado do servidor). Essa habilidade é providenciada por __adaptadores__, que são [integrações](/pt-br/reference/integrations-reference/). Veja o [guia de SSR](/pt-br/guides/server-side-rendering/) para aprender como utilizar um adaptador existente. ## O que é um adaptador diff --git a/src/content/docs/pt-br/reference/errors/no-adapter-installed.mdx b/src/content/docs/pt-br/reference/errors/no-adapter-installed.mdx index 881c324d31953..7ee20d6c21279 100644 --- a/src/content/docs/pt-br/reference/errors/no-adapter-installed.mdx +++ b/src/content/docs/pt-br/reference/errors/no-adapter-installed.mdx @@ -12,4 +12,4 @@ Para utilizar renderização no lado do servidor, um adaptador precisa ser insta **Veja Também:** - [Renderização no lado do Servidor](/pt-br/guides/server-side-rendering/) -- [Adicionando um Adaptador](/pt-br/guides/server-side-rendering/#adicionando-um-adaptador) +- [Adicionando um Adaptador](/pt-br/guides/server-side-rendering/) diff --git a/src/content/docs/pt-br/reference/errors/static-client-address-not-available.mdx b/src/content/docs/pt-br/reference/errors/static-client-address-not-available.mdx index a79bc003e3285..d4f3fa543a072 100644 --- a/src/content/docs/pt-br/reference/errors/static-client-address-not-available.mdx +++ b/src/content/docs/pt-br/reference/errors/static-client-address-not-available.mdx @@ -13,5 +13,5 @@ A propriedade `Astro.clientAddress` está apenas disponível quando [Renderizaç Para conseguir o endereço de IP do usuário no modo estático, diferentes APIs como [Ipify](https://www.ipify.org/) podem ser utilizadas em um [Script no lado do cliente](/pt-br/guides/client-side-scripts/) ou pode ser possível conseguir o IP do usuário utilizando uma função serverless hospedada no seu provedor de hospedagem. **Veja Também:** -- [Habilitando SSR no seu projeto](/pt-br/guides/server-side-rendering/#habilitando-o-ssr-em-seu-projeto) +- [Habilitando SSR no seu projeto](/pt-br/guides/server-side-rendering/) - [Astro.clientAddress](/pt-br/reference/api-reference/#astroclientaddress) diff --git a/src/content/docs/pt-br/reference/errors/static-redirect-not-available.mdx b/src/content/docs/pt-br/reference/errors/static-redirect-not-available.mdx index 0a03f96486838..c86acc426789f 100644 --- a/src/content/docs/pt-br/reference/errors/static-redirect-not-available.mdx +++ b/src/content/docs/pt-br/reference/errors/static-redirect-not-available.mdx @@ -16,6 +16,6 @@ A função `Astro.redirect` está apenas disponível quando [Renderização no l Para redirecionar em um site estático, o [atributo meta refresh](https://developer.mozilla.org/pt-BR/docs/Web/HTML/Element/meta) pode ser utilizado. Certas hospedagens também providenciam redirecionamentos baseados em configuração (ex: [Netlify redirects](https://docs.netlify.com/routing/redirects/)). **Veja Também:** -- [Habilitando SSR no seu projeto](/pt-br/guides/server-side-rendering/#habilitando-o-ssr-em-seu-projeto) +- [Habilitando SSR no seu projeto](/pt-br/guides/server-side-rendering/) - [Astro.redirect](/pt-br/reference/api-reference/#astroredirect) diff --git a/src/content/docs/ru/guides/deploy.mdx b/src/content/docs/ru/guides/deploy.mdx index e2d006dbdf763..396139a254670 100644 --- a/src/content/docs/ru/guides/deploy.mdx +++ b/src/content/docs/ru/guides/deploy.mdx @@ -78,7 +78,7 @@ npm run build :::note Перед тем, как развернуть ваш сайт Astro с [SSR (server-side rendering)](/ru/guides/server-side-rendering/) убедитесь, что вы: -- Установили [соответствующий адаптер](/ru/guides/server-side-rendering/#enabling-ssr-in-your-project) в зависимости вашего проекта (вручную или с помощью команды `astro add`, например, `npx astro add netlify`). +- Установили [соответствующий адаптер](/ru/guides/server-side-rendering/) в зависимости вашего проекта (вручную или с помощью команды `astro add`, например, `npx astro add netlify`). - [Добавили адаптер](/ru/reference/configuration-reference/#integrations) в ваш файл `astro.config.mjs` в виде импорта и экспорта по умолчанию при установке вручную.. (Команда `astro add` возьмет на себя этот шаг!) ::: diff --git a/src/content/docs/zh-cn/core-concepts/endpoints.mdx b/src/content/docs/zh-cn/core-concepts/endpoints.mdx index 1c714401cf152..1a95e58f8c7f1 100644 --- a/src/content/docs/zh-cn/core-concepts/endpoints.mdx +++ b/src/content/docs/zh-cn/core-concepts/endpoints.mdx @@ -98,7 +98,7 @@ export const GET: APIRoute = ({ params, request }) => { :::note -在尝试这些示例之前,请务必确认已经 [启用了 SSR](/zh-cn/guides/server-side-rendering/#启用-ssr)。 +在尝试这些示例之前,请务必确认已经 [启用了 SSR](/zh-cn/guides/server-side-rendering/)。 ::: 服务器端点可以在不导出 `getStaticPaths` 的情况下访问 `params`。服务器端点可以返回一个 [`Response`](https://developer.mozilla.org/zh-CN/docs/Web/API/Response) 对象,其允许你为返回的数据设置 `status codes` 和 `headers` diff --git a/src/content/docs/zh-cn/guides/backend/google-firebase.mdx b/src/content/docs/zh-cn/guides/backend/google-firebase.mdx index a687cf5ac4e0e..d668f0fbce295 100644 --- a/src/content/docs/zh-cn/guides/backend/google-firebase.mdx +++ b/src/content/docs/zh-cn/guides/backend/google-firebase.mdx @@ -18,7 +18,7 @@ import FileTree from '~/components/FileTree.astro' ### 前期准备 - 一个已配置了网页应用的 Firebase 项目; -- 一个开启了 [服务端渲染模式(SSR)](/zh-cn/guides/server-side-rendering/#启用-ssr) 的 Astro 项目; +- 一个开启了 [服务端渲染模式(SSR)](/zh-cn/guides/server-side-rendering/) 的 Astro 项目; - Firebase 凭据:你需要准备两组凭据来将 Astro 连接到 Firebase: - 网页应用凭据:这些凭据将用于你的应用的客户端部分。你可以在 Firebase 控制台的「项目设置 > 通用」下找到它们。向下滚动到「您的应用」部分,然后并点击「网页应用」图标; - 项目凭据:这些凭据将用于你的应用的服务器端部分。你可以在 Firebase 控制台的「项目设置 > 服务帐号 > Firebase Admin SDK > 生成新的私钥」下生成它们。 diff --git a/src/content/docs/zh-cn/guides/cms/contentful.mdx b/src/content/docs/zh-cn/guides/cms/contentful.mdx index a188a7509809a..cb661c4844793 100644 --- a/src/content/docs/zh-cn/guides/cms/contentful.mdx +++ b/src/content/docs/zh-cn/guides/cms/contentful.mdx @@ -425,7 +425,7 @@ const { content, title, date } = Astro.props; #### 服务器端渲染 -如果你已经 [选择使用 SSR 模式](/zh-cn/guides/server-side-rendering/#启用-ssr),你将使用一个使用 `slug` 参数从 Contentful 获取数据的动态路由。 +如果你已经 [选择使用 SSR 模式](/zh-cn/guides/server-side-rendering/),你将使用一个使用 `slug` 参数从 Contentful 获取数据的动态路由。 在 `src/pages/posts` 中创建一个 `[slug].astro` 页面。使用 [`Astro.params`](/zh-cn/reference/api-reference/#astroparams) 来从 URL 中获取 slug,然后将其传递给 `getEntries`: diff --git a/src/content/docs/zh-cn/guides/cms/storyblok.mdx b/src/content/docs/zh-cn/guides/cms/storyblok.mdx index 38f50b94394c1..7a80c28b6e0df 100644 --- a/src/content/docs/zh-cn/guides/cms/storyblok.mdx +++ b/src/content/docs/zh-cn/guides/cms/storyblok.mdx @@ -451,7 +451,7 @@ const story = data.story; #### 服务器端渲染 -如果你已经[启用了 SSR 模式](/zh-cn/guides/server-side-rendering/#启用-ssr),你将使用动态路由从 Storyblok 获取页面数据。 +如果你已经[启用了 SSR 模式](/zh-cn/guides/server-side-rendering/),你将使用动态路由从 Storyblok 获取页面数据。 在 `src/pages/blog/` 目录下创建一个名为 `[...slug].astro` 的新文件,并添加以下代码: diff --git a/src/content/docs/zh-cn/guides/cms/strapi.mdx b/src/content/docs/zh-cn/guides/cms/strapi.mdx index 19534a90a3d4b..83f7f541cabaf 100644 --- a/src/content/docs/zh-cn/guides/cms/strapi.mdx +++ b/src/content/docs/zh-cn/guides/cms/strapi.mdx @@ -319,7 +319,7 @@ const article = Astro.props; #### 服务器端渲染 -如果你选择了 [SSR 模式](/zh-cn/guides/server-side-rendering/#启用-ssr) 并设置了 `output: server` 或 `output: hybrid`,那么可以使用以下代码来生成你的[动态路由](/zh-cn/core-concepts/routing/#服务器ssr模式)。 +如果你选择了 [SSR 模式](/zh-cn/guides/server-side-rendering/) 并设置了 `output: server` 或 `output: hybrid`,那么可以使用以下代码来生成你的[动态路由](/zh-cn/core-concepts/routing/#服务器ssr模式)。 创建 `src/pages/blog/[slug].astro` 文件: diff --git a/src/content/docs/zh-cn/guides/deploy.mdx b/src/content/docs/zh-cn/guides/deploy.mdx index 7742d3ad548fc..7fabf43e46269 100644 --- a/src/content/docs/zh-cn/guides/deploy.mdx +++ b/src/content/docs/zh-cn/guides/deploy.mdx @@ -77,6 +77,6 @@ npm run build :::note 在使用 [SSR(服务端渲染)](/zh-cn/guides/server-side-rendering/) 部署你的 Astro 站点前,请确保: - - 在项目依赖中安装[合适的适配器](/zh-cn/guides/server-side-rendering/#启用-ssr)(手动安装,或者使用适配器的 `astro add` 命令,例如,`npx astro add netlify`)。 + - 在项目依赖中安装[合适的适配器](/zh-cn/guides/server-side-rendering/)(手动安装,或者使用适配器的 `astro add` 命令,例如,`npx astro add netlify`)。 - 手动安装时,需要在你的 `astro.config.mjs` 文件导入和默认导出中[加上适配器](/zh-cn/reference/configuration-reference/#集成)。(`astro add` 命令将为你处理此步骤!) ::: diff --git a/src/content/docs/zh-cn/guides/imports.mdx b/src/content/docs/zh-cn/guides/imports.mdx index 98aaf54b3620c..ec49f0bca5b00 100644 --- a/src/content/docs/zh-cn/guides/imports.mdx +++ b/src/content/docs/zh-cn/guides/imports.mdx @@ -218,7 +218,7 @@ Astro 支持使用浏览器的 [`WebAssembly`](https://developer.mozilla.org/en- ## Node 内置模块 -我们鼓励 Astro 用户尽可能避免使用 Node.js 内置模块(`fs`、`path` 等)。Astro 兼容多个运行时使用 [适配器](/zh-cn/guides/server-side-rendering/#添加一个适配器)。这包括 [Deno](https://github.com/denoland/deno-astro-adapter) 和 [Cloudflare Workers](/zh-cn/guides/integrations-guide/cloudflare/),它们不支持 Node 内置模块,例如 `fs`。 +我们鼓励 Astro 用户尽可能避免使用 Node.js 内置模块(`fs`、`path` 等)。Astro 兼容多个运行时使用 [适配器](/zh-cn/guides/server-side-rendering/)。这包括 [Deno](https://github.com/denoland/deno-astro-adapter) 和 [Cloudflare Workers](/zh-cn/guides/integrations-guide/cloudflare/),它们不支持 Node 内置模块,例如 `fs`。 我们致力于为常用的 Node.js 内置模块提供 Astro 化的替代品,不过现在还没有实现。因此,如果你**真的**需要,我们不会阻止你使用这些内置模块。Astro 支持使用较新 `node:` 前缀来支持 Node.js 内置模块。例如,如果你想读取一个文件,你可以这样做: diff --git a/src/content/docs/zh-cn/guides/integrations-guide/deno.mdx b/src/content/docs/zh-cn/guides/integrations-guide/deno.mdx index c1edab085f2db..51cf8b4bbf7a3 100644 --- a/src/content/docs/zh-cn/guides/integrations-guide/deno.mdx +++ b/src/content/docs/zh-cn/guides/integrations-guide/deno.mdx @@ -8,4 +8,4 @@ Deno 适配器允许 Astro 将 SSR 站点部署到 Deno,包括 Deno Deploy。 Deno 适配器以前由 Astro 维护,但现在由 Deno 直接维护。使用方法现在在 [Deno 适配器仓库](https://github.com/denoland/deno-astro-adapter)。 -如果你目前正在使用此 Astro 适配器,则需要迁移到新的 Deno 版本或 [添加另一个适配器](/zh-cn/guides/server-side-rendering/#添加一个适配器) 以继续在项目中使用 SSR。 +如果你目前正在使用此 Astro 适配器,则需要迁移到新的 Deno 版本或 [添加另一个适配器](/zh-cn/guides/server-side-rendering/) 以继续在项目中使用 SSR。 diff --git a/src/content/docs/zh-cn/guides/migrate-to-astro/from-gatsby.mdx b/src/content/docs/zh-cn/guides/migrate-to-astro/from-gatsby.mdx index 50fd4f42a3e67..685886f213c2c 100644 --- a/src/content/docs/zh-cn/guides/migrate-to-astro/from-gatsby.mdx +++ b/src/content/docs/zh-cn/guides/migrate-to-astro/from-gatsby.mdx @@ -238,7 +238,7 @@ Gatsby 有几个顶级配置文件,也包括站点和页面元数据,并用 - `gatsby-node.js`:在 Astro 中你不需要创建你自己的节点,但查看该文件中的 schema 可能有助于你在 Astro 项目中定义类型。 -- `gatsby-ssr.js`:如果你选择在 Astro 中使用 SSR,你将在 `astro.config.mjs` 中[添加和配置你选择的 SSR 适配器](/zh-cn/guides/server-side-rendering/#添加一个适配器)。 +- `gatsby-ssr.js`:如果你选择在 Astro 中使用 SSR,你将在 `astro.config.mjs` 中[添加和配置你选择的 SSR 适配器](/zh-cn/guides/server-side-rendering/)。 ## 参考:转换为 Astro 语法 diff --git a/src/content/docs/zh-cn/guides/rss.mdx b/src/content/docs/zh-cn/guides/rss.mdx index fa0245349ef97..4cee396de67e9 100644 --- a/src/content/docs/zh-cn/guides/rss.mdx +++ b/src/content/docs/zh-cn/guides/rss.mdx @@ -11,7 +11,7 @@ Astro 支持为博客和其他内容网站快速,自动的 RSS 提要生成。 ## 设置 `@astrojs/rss` -[`@astrojs/rss` 包](https://github.com/withastro/astro/tree/main/packages/astro-rss) 提供了使用 [API 端点](/zh-cn/core-concepts/endpoints/#静态文件端点) 生成 RSS 摘要的帮助程序。这使得静态构建和使用 [SSR 适配器](/zh-cn/guides/server-side-rendering/#添加一个适配器) 时的按需生成都成为可能。 +[`@astrojs/rss` 包](https://github.com/withastro/astro/tree/main/packages/astro-rss) 提供了使用 [API 端点](/zh-cn/core-concepts/endpoints/#静态文件端点) 生成 RSS 摘要的帮助程序。这使得静态构建和使用 [SSR 适配器](/zh-cn/guides/server-side-rendering/) 时的按需生成都成为可能。 1. 使用你喜欢的包管理器安装 `@astrojs/rss`: diff --git a/src/content/docs/zh-cn/reference/adapter-reference.mdx b/src/content/docs/zh-cn/reference/adapter-reference.mdx index 48b59f34f3f8f..f335cad2d5fe5 100644 --- a/src/content/docs/zh-cn/reference/adapter-reference.mdx +++ b/src/content/docs/zh-cn/reference/adapter-reference.mdx @@ -5,7 +5,7 @@ title: Astro 适配器 API import Since from '~/components/Since.astro'; import FileTree from '~/components/FileTree.astro'; -Astro 可以轻松部署到任何云托管平台,以实现服务端渲染(SSR)。该能力由**适配器**[集成](/zh-cn/reference/integrations-reference/)提供,请参阅 [SSR 指南](/zh-cn/guides/server-side-rendering/#添加一个适配器) 了解如何使用现有的适配器。 +Astro 可以轻松部署到任何云托管平台,以实现服务端渲染(SSR)。该能力由**适配器**[集成](/zh-cn/reference/integrations-reference/)提供,请参阅 [SSR 指南](/zh-cn/guides/server-side-rendering/) 了解如何使用现有的适配器。 ## 什么是适配器 diff --git a/src/content/docs/zh-cn/reference/errors/no-adapter-installed.mdx b/src/content/docs/zh-cn/reference/errors/no-adapter-installed.mdx index 8a861ad9db4ef..ad884e80b05fd 100644 --- a/src/content/docs/zh-cn/reference/errors/no-adapter-installed.mdx +++ b/src/content/docs/zh-cn/reference/errors/no-adapter-installed.mdx @@ -13,4 +13,4 @@ githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/ **请参阅:** - [服务端渲染](/zh-cn/guides/server-side-rendering/) -- [添加适配器](/zh-cn/guides/server-side-rendering/#添加一个适配器) +- [添加适配器](/zh-cn/guides/server-side-rendering/) diff --git a/src/content/docs/zh-cn/reference/errors/static-client-address-not-available.mdx b/src/content/docs/zh-cn/reference/errors/static-client-address-not-available.mdx index 59fb858288b7f..f4e1fc5e0edc9 100644 --- a/src/content/docs/zh-cn/reference/errors/static-client-address-not-available.mdx +++ b/src/content/docs/zh-cn/reference/errors/static-client-address-not-available.mdx @@ -14,5 +14,5 @@ githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/ **请参阅:** -- [在项目中启用 SSR](/zh-cn/guides/server-side-rendering/#启用-ssr) +- [在项目中启用 SSR](/zh-cn/guides/server-side-rendering/) - [Astro.clientAddress](/zh-cn/reference/api-reference/#astroclientaddress) diff --git a/src/content/docs/zh-cn/reference/errors/static-redirect-not-available.mdx b/src/content/docs/zh-cn/reference/errors/static-redirect-not-available.mdx index 66c225df0052a..68d474f8ca73d 100644 --- a/src/content/docs/zh-cn/reference/errors/static-redirect-not-available.mdx +++ b/src/content/docs/zh-cn/reference/errors/static-redirect-not-available.mdx @@ -18,5 +18,5 @@ githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/ **请参阅:** -- [在项目中启用 SSR](/zh-cn/guides/server-side-rendering/#启用-ssr) +- [在项目中启用 SSR](/zh-cn/guides/server-side-rendering/) - [Astro.redirect](/zh-cn/reference/api-reference/#astroredirect) diff --git a/src/content/docs/zh-tw/guides/deploy.mdx b/src/content/docs/zh-tw/guides/deploy.mdx index 67ee86b6a07d5..c0f1a46d049c2 100644 --- a/src/content/docs/zh-tw/guides/deploy.mdx +++ b/src/content/docs/zh-tw/guides/deploy.mdx @@ -75,7 +75,7 @@ npm run build :::note 在使用 [SSR(伺服器渲染)](/zh-tw/guides/server-side-rendering/)來部署你的 Astro 網站之前,請先確定以下事項: - - 安裝好[適當的 adapter](/zh-tw/guides/server-side-rendering/#enabling-ssr-in-your-project) 到你的專案相依模組(手動安裝或是用 adapter 的 `astro add` 指令,例如 `npx astro add netlify` )。 + - 安裝好[適當的 adapter](/zh-tw/guides/server-side-rendering/) 到你的專案相依模組(手動安裝或是用 adapter 的 `astro add` 指令,例如 `npx astro add netlify` )。 - 若是手動安裝,[加入 adapter](/zh-tw/reference/configuration-reference/#integrations) 到你的 `astro.config.mjs` 檔案的 import 和 default export( `astro add` 指令會為你執行這步驟)。 :::