Skip to content

Commit 2f663fc

Browse files
authored
Merge branch 'main' into 5.14.0
2 parents 3b38832 + 1eb485c commit 2f663fc

File tree

15 files changed

+234
-87
lines changed

15 files changed

+234
-87
lines changed

src/content/docs/es/reference/publish-to-npm.mdx

Lines changed: 27 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ title: Publica en NPM
33
description: Aprende a publicar componentes de Astro en NPM
44
i18nReady: true
55
---
6+
import { Steps } from '@astrojs/starlight/components';
67
import { FileTree } from '@astrojs/starlight/components';
78

89
¿Construyendo un nuevo componente Astro? **¡Publícalo en [npm](https://npmjs.com/)!**
@@ -234,17 +235,21 @@ Astro actualmente no incluye un test runner. Esto es algo que nos gustaría abor
234235

235236
Mientras tanto, nuestra recomendación actual para las pruebas es:
236237

238+
<Steps>
237239
1. Agrega un directorio `fixtures` de prueba a su directorio `demo/src/pages`.
240+
238241
2. Agrega una nueva página para cada prueba que desee ejecutar.
242+
239243
3. Cada página debe incluir un uso distinto de los componentes que te gustaría probar.
240-
4. Ejecuta `astro build` para construir tus fixtures, luego compara los resultados en el directorio `dist/__fixtures__/` con los resultados esperados.
241244

242-
<FileTree>
243-
- my-project/demo/src/pages/\_\_fixtures\_\_/
244-
- test-name-01.astro
245-
- test-name-02.astro
246-
- test-name-03.astro
247-
</FileTree>
245+
4. Ejecuta `astro build` para construir tus fixtures, luego compara los resultados en el directorio `dist/__fixtures__/` con los resultados esperados.
246+
<FileTree>
247+
- my-project/demo/src/pages/\_\_fixtures\_\_/
248+
- test-name-01.astro
249+
- test-name-02.astro
250+
- test-name-03.astro
251+
</FileTree>
252+
</Steps>
248253

249254
## Publicando tu componente
250255

@@ -274,19 +279,24 @@ La biblioteca de integraciones lee los datos `name`, `description`, `repository`
274279
¿Necesitas anular la información que nuestra biblioteca lee de NPM? ¡No hay problema! [Crea una issue](https://github.com/withastro/astro.build/issues/new/choose) con la información actualizada y nos aseguraremos de que el `nombre`, la `descripción` o la `página de inicio` personalizados sean utilizados en su lugar.
275280
:::
276281

277-
### Colecciones
282+
### Categorías
278283

279-
Además de la palabra clave requerida `astro-component` o `withastro`, también se utilizan otras palabras clave especiales para organizar automáticamente los paquetes. Incluir cualquiera de las palabras clave a continuación agregará tu integración a la colección en nuestra biblioteca de integraciones.
284+
Además de la palabra clave requerida `astro-component` o `withastro`, también se utilizan otras palabras clave especiales para organizar automáticamente los paquetes. Incluir cualquiera de las palabras clave a continuación agregará tu integración a la categoría en nuestra biblioteca de integraciones.
280285

281-
| colección | palabras clave |
282-
| ----------------- | -------------------------------------------- |
283-
| Accesibilidad | `a11y`, `accessibility` |
284-
| Adaptadores | `astro-adapter` |
285-
| Analíticas | `analytics` |
286-
| CSS + UI | `css`, `ui`, `icon`, `icons`, `renderer` |
287-
| Frameworks | `renderer` |
288-
| Performance + SEO | `performance`, `perf`, `seo`, `optimization` |
286+
| categoría | palabras clave |
287+
| ------------------------- | -------------------------------------------- |
288+
| Accesibilidad | `a11y`, `accessibility` |
289+
| Adaptadores | `astro-adapter` |
290+
| Analíticas | `analytics` |
291+
| CSS + UI | `css`, `ui`, `icon`, `icons`, `renderer` |
292+
| Frameworks | `renderer` |
293+
| Cargadores de contenido | `astro-loader` |
294+
| Imágenes + Medios | `image`, `images`, `media` |
295+
| Rendimiento + SEO | `performance`, `perf`, `seo`, `optimization` |
296+
| Barra de herramientas | `devtools`, `dev-overlay`, `dev-toolbar` |
297+
| Utilidades | `tooling`, `utils`, `utility` |
289298

299+
Los paquetes que no incluyan ninguna palabra clave que coincida con una categoría se mostrarán como `Uncategorized`.
290300

291301
## Comparte
292302

src/content/docs/es/upgrade-astro.mdx

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import Version from '~/components/Version.astro';
1212
Esta guía cubre como actualizar tu versión de Astro y las dependencias relacionadas, cómo aprender qué ha cambiado de una versión a otra y cómo entender el sistema de versiones de Astro y sus correspondientes actualizaciones de documentación.
1313

1414
## ¿Qué ha cambiado?
15+
1516
La última versión de Astro es <Version pkgName="astro"/>
1617

1718
Puedes encontrar una lista detallada de todos los cambios en el [historial de cambios de Astro](https://github.com/withastro/astro/blob/main/packages/astro/CHANGELOG.md) e instrucciones importantes para actualizar a cada nueva [versión mayor](#cambios-mayores) en nuestras [guías de actualización](#guías-de-actualización).
@@ -48,20 +49,20 @@ Para actualizar Astro y sus dependencias a sus últimas versiones manualmente, u
4849
<PackageManagerTabs>
4950
<Fragment slot="npm">
5051
```shell
51-
# Ejemplo: actualiza Astro con las integraciones de React y Tailwind
52-
npm install astro@latest @astrojs/react@latest @astrojs/tailwind@latest
52+
# Ejemplo: actualiza Astro con las integraciones de React y Partytown
53+
npm install astro@latest @astrojs/react@latest @astrojs/partytown@latest
5354
```
5455
</Fragment>
5556
<Fragment slot="pnpm">
5657
```shell
57-
# Ejemplo: actualiza Astro con las integraciones de React y Tailwind
58-
pnpm add astro@latest @astrojs/react@latest @astrojs/tailwind@latest
58+
# Ejemplo: actualiza Astro con las integraciones de React y Partytown
59+
pnpm add astro@latest @astrojs/react@latest @astrojs/partytown@latest
5960
```
6061
</Fragment>
6162
<Fragment slot="yarn">
6263
```shell
63-
# Ejemplo: actualiza Astro con las integraciones de React y Tailwind
64-
yarn add astro@latest @astrojs/react@latest @astrojs/tailwind@latest
64+
# Ejemplo: actualiza Astro con las integraciones de React y Partytown
65+
yarn add astro@latest @astrojs/react@latest @astrojs/partytown@latest
6566
```
6667
</Fragment>
6768
</PackageManagerTabs>
@@ -118,7 +119,6 @@ La documentación para las versiones antiguas de Astro no es mantenida, pero est
118119
- [versión v3.6.3 no mantenida](https://docs-git-v3-docs-unmaintained-astrodotbuild.vercel.app/)
119120
- [versión v2.10.15 no mantenida](https://deploy-preview-4405--astro-docs-2.netlify.app/en/getting-started/)
120121

121-
122122
## Versionado semántico
123123

124124
Astro intenta seguir tanto como pueda un [versionado semántico](https://semver.org/), el cuál es un grupo de reglas de desarrollo usados para determinar cómo asignar una versión numérica a un lanzamiento. El versionado semántico sigue un patrón predecible para informar a los usuarios el tipo de cambios que pueden esperar de una versión a la otra.
@@ -143,7 +143,6 @@ Los parches pueden ser lanzados por razones como:
143143

144144
Los parches incluyen también la **mayoría de correciones de errores**, incluso en casos donde los usuarios abusaban de un comportamiento no deseado.
145145

146-
147146
### Cambios menores
148147

149148
Los cambios menores principalmente introducen nuevas características y mejoras que podrías probar, pero sin cambios en tu código. Algunas características existentes podrían ser **obsoletas** (marcadas para eliminación en una versión futura mientras aún están disponibles en la versión actual) en una versión menor, dándote la oportunidad de prepararlas para una eliminación eventual.

src/content/docs/fr/guides/routing.mdx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -318,6 +318,8 @@ if (!isLoggedIn(cookie)) {
318318
---
319319
```
320320

321+
Étant donné qu'Astro utilise le [streaming HTML](/fr/guides/on-demand-rendering/#streaming-html) dans le rendu à la demande, les redirections doivent être effectuées au niveau de la page, et non à l'intérieur des composants enfants.
322+
321323
## Réécritures
322324

323325
<p><Since v="4.13.0" /></p>

src/content/docs/ko/guides/integrations-guide/alpinejs.mdx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@ githubIntegrationURL: 'https://github.com/withastro/astro/tree/main/packages/int
88
category: renderer
99
i18nReady: true
1010
---
11-
import PackageManagerTabs from '~/components/tabs/PackageManagerTabs.astro'
11+
import PackageManagerTabs from '~/components/tabs/PackageManagerTabs.astro';
12+
import Since from '~/components/Since.astro';
1213

1314
**[Astro 통합][astro-integration]** 프로젝트에 [Alpine.js](https://alpinejs.dev/)를 추가하므로 페이지 어디에서나 Alpine.js를 사용할 수 있습니다.
1415

@@ -96,6 +97,12 @@ export default defineConfig({
9697

9798
### `entrypoint`
9899

100+
<p>
101+
102+
**타입:** `string`<br />
103+
<Since v="0.4.0" pkg="@astrojs/alpinejs" />
104+
</p>
105+
99106
`entrypoint` 옵션을 루트 상대 가져오기 지정자 (예: `entrypoint: "/src/entrypoint"`)로 설정하여 Alpine을 확장할 수 있습니다.
100107

101108
이 파일의 기본 내보내기는 시작하기 전에 Alpine 인스턴스를 허용하는 함수여야 합니다. 이를 통해 고급 사용 사례에 맞게 사용자 정의 지시어, 플러그인, 기타 맞춤 설정을 사용할 수 있습니다.

src/content/docs/ko/guides/integrations-guide/db.mdx

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,11 @@ export default defineConfig({
129129

130130
### `columns`
131131

132+
<p>
133+
134+
**타입:** `ColumnsConfig`
135+
</p>
136+
132137
테이블 열은 `columns` 객체를 사용하여 구성됩니다.
133138

134139
```ts
@@ -184,6 +189,11 @@ type UserTableInferInsert = {
184189
185190
### `indexes`
186191
192+
<p>
193+
194+
**타입:** `{ on: string | string[]; unique?: boolean | undefined; name?: string | undefined; }[]`
195+
</p>
196+
187197
테이블 인덱스는 특정 열 또는 열 조합에 대한 조회 속도를 향상시키는 데 사용됩니다. `indexes` 속성은 인덱스를 생성할 열을 지정하는 구성 객체의 배열을 값으로 전달받습니다.
188198
189199
```ts title="db/config.ts" {9-11}
@@ -205,12 +215,17 @@ const Comment = defineTable({
205215

206216
각 인덱스에 대해 다음 구성 옵션을 사용할 수 있습니다.
207217

208-
- `on`: `string | string[]` - 인덱싱할 단일 열 또는 열 이름 배열입니다.
209-
- `unique`: `boolean` - 인덱스가 생성된 열 전체에 고유한 값을 적용하려면 `true`로 설정합니다.
210-
- `name`: `string` (선택 사항) - 고유 인덱스의 사용자 정의 이름입니다. 이는 색인화되는 테이블 및 열 이름을 기반으로 Astro에서 생성된 이름을 재정의합니다 (예: `Comment_authorId_published_idx`). 사용자 정의 이름은 전역적이므로 인덱스 이름이 테이블 간에 충돌하지 않는지 확인하세요.
218+
- `on` - 인덱싱할 단일 열 또는 열 이름 배열입니다.
219+
- `unique` (선택 사항) - 인덱스가 생성된 열 전체에 고유한 값을 적용하려면 `true`로 설정합니다.
220+
- `name` (선택 사항) - 고유 인덱스의 사용자 정의 이름입니다. 이는 색인화되는 테이블 및 열 이름을 기반으로 Astro에서 생성된 이름을 재정의합니다 (예: `Comment_authorId_published_idx`). 사용자 정의 이름은 전역적이므로 인덱스 이름이 테이블 간에 충돌하지 않는지 확인하세요.
211221

212222
### `foreignKeys`
213223

224+
<p>
225+
226+
**타입:** `{ columns: string | string[]; references: () => Column | Column[]; }[]`
227+
</p>
228+
214229
:::tip
215230

216231
`foreignKeys`는 여러 테이블 열을 연결하기 위한 고급 API입니다. 단일 열만 참조해야 하는 경우 [`references` 속성](#columns)을 사용하세요.
@@ -246,8 +261,8 @@ const Comment = defineTable({
246261

247262
각 외래 키 구성 객체는 다음 속성을 허용합니다.
248263

249-
- `columns`: `string[]` - 참조된 테이블과 관련된 열 이름의 배열입니다.
250-
- `references`: `() => Column[]` - 참조된 테이블에서 열 배열을 반환하는 함수입니다.
264+
- `columns` - 참조된 테이블과 관련된 단일 열 또는 열 이름의 배열입니다.
265+
- `references` - 참조된 테이블에서 단일 열 또는 열 배열을 반환하는 함수입니다.
251266

252267
## Astro DB CLI 참조
253268

@@ -288,6 +303,12 @@ Astro DB에는 로컬 및 libSQL 호환 데이터베이스와 상호 작용하
288303

289304
### `isDbError()`
290305

306+
<p>
307+
308+
**타입:** `(err: unknown) => boolean`<br />
309+
<Since v="0.9.1" pkg="@astrojs/db" />
310+
</p>
311+
291312
`isDbError()` 함수는 오류가 libSQL 데이터베이스 예외인지 확인합니다. 여기에는 참조 사용 시 외래 키 제약 조건 오류가 포함되거나 데이터 삽입 시 필드 누락이 포함될 수 있습니다. `isDbError()`를 try / catch 블록과 결합하여 애플리케이션의 데이터베이스 오류를 처리할 수 있습니다.
292313

293314
```ts title="src/pages/api/comment/[id].ts" "idDbError"

src/content/docs/ko/guides/integrations-guide/markdoc.mdx

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ githubIntegrationURL: 'https://github.com/withastro/astro/tree/main/packages/int
88
category: other
99
i18nReady: true
1010
---
11-
import { FileTree } from '@astrojs/starlight/components';
11+
import { FileTree, Steps } from '@astrojs/starlight/components';
1212
import PackageManagerTabs from '~/components/tabs/PackageManagerTabs.astro';
13-
import { Steps } from '@astrojs/starlight/components';
1413
import ReadMore from '~/components/ReadMore.astro';
14+
import Since from '~/components/Since.astro';
1515

1616
**[Astro 통합][astro-integration]** 통해 [Markdoc](https://markdoc.dev/)을 사용하여 컴포넌트, 페이지 및 콘텐츠 컬렉션 항목을 생성할 수 있습니다.
1717

@@ -589,6 +589,13 @@ Astro Markdoc 통합은 `markdoc.config.js` 파일을 통해 사용할 수 없
589589
590590
### `allowHTML`
591591
592+
<p>
593+
594+
**타입:** `boolean`<br />
595+
**기본값:** `false`<br />
596+
<Since v="0.4.4" pkg="@astrojs/markdoc" />
597+
</p>
598+
592599
Markdoc 태그 및 노드와 함께 HTML 마크업 작성을 활성화합니다.
593600
594601
기본적으로 Markdoc은 HTML 마크업을 의미 있는 콘텐츠로 인식하지 않습니다.
@@ -611,6 +618,13 @@ Markdoc 태그 및 노드와 함께 HTML 마크업 작성을 활성화합니다.
611618
612619
### `ignoreIndentation`
613620
621+
<p>
622+
623+
**타입:** `boolean`<br />
624+
**기본값:** `false`<br />
625+
<Since v="0.7.0" pkg="@astrojs/markdoc" />
626+
</p>
627+
614628
기본적으로 공백 4개로 들여쓰기된 모든 콘텐츠는 코드 블록으로 처리됩니다. 불행하게도 이 동작은 복잡한 구조를 가진 문서의 가독성을 향상시키기 위해 임의 수준의 들여쓰기를 사용하기 어렵게 만듭니다.
615629
616630
Markdoc에서 중첩 태그를 사용할 때 깊이 수준이 명확하도록 태그 내부의 내용을 들여쓰는 것이 도움이 될 수 있습니다. 임의 들여쓰기를 지원하려면 들여쓰기 기반 코드 블록을 비활성화하고 들여쓰기 기반 코드 블록을 설명하는 몇 가지 다른 markdown-it 구문 분석 규칙을 수정해야 합니다. 이러한 변경 사항은 ignoreIndentation 옵션을 활성화하여 적용할 수 있습니다.

src/content/docs/ko/guides/integrations-guide/mdx.mdx

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -273,8 +273,12 @@ MDX는 remark 및 rehype 플러그인을 문자열로 전달하는 것을 지원
273273

274274
### `extendMarkdownConfig`
275275

276-
* **타입:** `boolean`
277-
* **기본값:** `true`
276+
<p>
277+
278+
**타입:** `boolean`<br />
279+
**기본값:** `true`<br />
280+
<Since v="0.15.0" pkg="@astrojs/mdx" />
281+
</p>
278282

279283
MDX는 기본적으로 [프로젝트의 기존 Markdown 구성](/ko/reference/configuration-reference/#markdown-옵션)을 확장합니다. 개별 옵션을 재정의하려면 MDX 구성에서 해당 옵션을 지정하면 됩니다.
280284

@@ -328,13 +332,25 @@ export default defineConfig({
328332

329333
### `recmaPlugins`
330334

335+
<p>
336+
337+
**타입:** `PluggableList`<br />
338+
**기본값:** `[]`<br />
339+
<Since v="0.11.5" pkg="@astrojs/mdx" />
340+
</p>
341+
331342
출력되는 [estree](https://github.com/estree/estree)를 직접 수정하는 플러그인입니다. 이는 MDX 파일에서 JavaScript 변수를 수정하거나 삽입하는 데 유용합니다.
332343

333344
[AST Explorer를 사용](https://astexplorer.net/)하여 estree 출력을 수행하고 [`estree-util-visit`](https://unifiedjs.com/explore/package/estree-util-visit/)를 사용하여 JavaScript 노드를 검색하는 것이 좋습니다.
334345

335346
### `optimize`
336347

337-
* **타입:** `boolean | { ignoreElementNames?: string[] }`
348+
<p>
349+
350+
**타입:** `boolean | { ignoreElementNames?: string[] }`<br />
351+
**기본값:** `false`<br />
352+
<Since v="0.19.5" pkg="@astrojs/mdx" />
353+
</p>
338354

339355
이는 내부 rehype 플러그인을 통해 더 빠른 빌드 및 렌더링을 위해 MDX 출력을 최적화하기 위한 선택적 구성 설정입니다. MDX 파일이 많고 빌드 속도가 느린 경우에 유용할 수 있습니다. 그러나 이 옵션은 일부 이스케이프 처리되지 않은 HTML을 생성할 수 있으므로 활성화한 후에도 사이트의 대화형 부분이 여전히 올바르게 작동하는지 확인하세요.
340356

@@ -356,9 +372,12 @@ export default defineConfig({
356372

357373
#### `ignoreElementNames`
358374

359-
* **타입:** `string[]`
375+
<p>
376+
377+
**타입:** `string[]`<br />
378+
<Since v="3.0.0" pkg="@astrojs/mdx" />
379+
</p>
360380

361-
<p><Since pkg="@astrojs/mdx" v="3.0.0" /></p>
362381
이전에는 `customComponentNames`로 알려졌습니다.
363382

364383
MDX 최적화 프로그램이 [컴포넌트 prop을 통해 가져온 MDX 콘텐츠에 전달된 사용자 정의 컴포넌트](/ko/guides/integrations-guide/mdx/#가져온-mdx를-사용하는-사용자-정의-컴포넌트)와 같은 특정 요소 이름을 처리하지 못하도록 방지하는 `optimize`의 선택적 속성입니다.

0 commit comments

Comments
 (0)