Skip to content

Commit

Permalink
i18n(ko-KR): update configuration-reference.mdx, `error-reference.m…
Browse files Browse the repository at this point in the history
…dx`, `/reference/errors/` (#8991)

* i18n(ko-KR): update `error-reference.mdx`

* i18n(ko-KR): update error mdx files

* i18n(ko-KR): update `configuration-reference.mdx`

* i18n(ko-KR): update `error-reference.mdx` and add new error reference file

---------

Co-authored-by: Yan <61414485+yanthomasdev@users.noreply.github.com>
  • Loading branch information
jsparkdev and yanthomasdev authored Aug 5, 2024
1 parent 0775ced commit 8189937
Show file tree
Hide file tree
Showing 7 changed files with 49 additions and 110 deletions.
102 changes: 0 additions & 102 deletions src/content/docs/ko/reference/configuration-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -1419,53 +1419,6 @@ export function Comment({ postId }: { postId: string }) {
}
```

### experimental.contentCollectionJsonSchema

<p>

**타입:** `boolean`<br />
**기본값:** `false`<br />
<Since v="4.5.0" />
</p>

이 기능은 VSCode와 같은 도구에서 TypeScript 스타일 자동 완성/힌트에 대한 `$schema` 값으로 사용할 수 있는 `type: 'data'` 콘텐츠 컬렉션에 대한 JSON 스키마를 자동으로 생성합니다.

이 기능을 활성화하려면 experimental 플래그를 추가하세요.

```diff
import { defineConfig } from 'astro/config';
export default defineConfig({
experimental: {
+ contentCollectionJsonSchema: true
}
});
```

이 실험적 구현에서는 컬렉션의 각 데이터 항목 파일에 있는 스키마를 수동으로 참조해야 합니다.

```diff
// src/content/test/entry.json
{
+ "$schema": "../../../.astro/collections/test.schema.json",
"test": "test"
}
```

또는 [VSCode `json.schemas` 설정](https://code.visualstudio.com/docs/languages/json#_json-schemas-and-settings)에서 이를 설정할 수 있습니다.

```diff
"json.schemas": [
{
"fileMatch": [
"/src/content/test/**"
],
"url": "../../../.astro/collections/test.schema.json"
}
]
```

이 초기 구현은 [고급 Zod 스키마에 대해 알려진 문제](https://github.com/StefanTerdell/zod-to-json-schema#known-issues)가 있는 라이브러리를 사용하므로 실험적 플래그를 활성화하기 전에 이러한 제한 사항을 참조하는 것이 좋습니다.

### experimental.clientPrerender

<p>
Expand Down Expand Up @@ -1533,61 +1486,6 @@ export default defineConfig({

경로 우선순위가 동일한 두 경로가 동일한 URL을 빌드하려고 시도하는 경로 충돌이 발생하는 경우 Astro는 충돌하는 경로를 식별하는 경고를 기록합니다.

### experimental.rewriting

<p>

**타입:** `boolean`<br />
**기본값:** `false`<br />
<Since v="4.8.0" />
</p>

Astro 페이지, 엔드포인트 및 Astro 미들웨어에서 요청을 리라이팅하기 위한 라우팅 기능을 활성화하여 경로를 프로그래밍 방식으로 제어할 수 있습니다.

```js
{
experimental: {
rewriting: true,
},
}
```

다른 페이지로 다시 라우팅하려면 `.astro` 파일에서 `Astro.rewrite`를 사용합니다.

```astro "rewrite"
---
// src/pages/dashboard.astro
if (!Astro.props.allowed) {
return Astro.rewrite("/")
}
---
```

다른 페이지로 다시 라우팅하려면 엔드포인트 파일에서 `context.rewrite`를 사용합니다.

```js
// src/pages/api.js
export function GET(ctx) {
if (!ctx.locals.allowed) {
return ctx.rewrite("/")
}
}
```

미들웨어 파일에서 `next("/")`를 사용하여 다른 페이지로 다시 라우팅한 후 다음 미들웨어 함수를 호출합니다.

```js
// src/middleware.js
export function onRequest(ctx, next) {
if (!ctx.cookies.get("allowed")) {
return next("/") // 새 시그니처
}
return next();
}
```

전체 개요를 확인하고 이 실험적 API에 대한 피드백을 제공하려면 [RFC 리라우팅](https://github.com/withastro/roadmap/blob/feat/reroute/proposals/0047-rerouting.md)을 참조하세요.

### experimental.env

<p>
Expand Down
8 changes: 7 additions & 1 deletion src/content/docs/ko/reference/error-reference.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -113,5 +113,11 @@ import DontEditWarning from '~/components/DontEditWarning.astro'
- [**ContentCollectionTypeMismatchError**](/ko/reference/errors/content-collection-type-mismatch-error/)<br/>컬렉션에 다른 타입의 항목이 포함되어 있습니다.
- [**DataCollectionEntryParseError**](/ko/reference/errors/data-collection-entry-parse-error/)<br/>데이터 컬렉션 항목을 구문 분석하지 못했습니다.
- [**DuplicateContentEntrySlugError**](/ko/reference/errors/duplicate-content-entry-slug-error/)<br/>콘텐츠 항목 슬러그가 중복되었습니다.
- [**ActionsWithoutServerOutputError**](/ko/reference/errors/actions-without-server-output-error/)<br/>액션은 서버 출력과 함께 사용해야 합니다.
- [**UnsupportedConfigTransformError**](/ko/reference/errors/unsupported-config-transform-error/)<br/>콘텐츠 구성에서 지원되지 않는 변환입니다.

## 액션 오류

- [**ActionsWithoutServerOutputError**](/ko/reference/errors/actions-without-server-output-error/)<br/>액션은 서버 출력과 함께 사용해야 합니다.
- [**ActionsUsedWithForGetError**](/ko/reference/errors/actions-used-with-for-get-error/)<br/>양식에서 잘못된 Action 쿼리 문자열을 전달했습니다.
- [**ActionQueryStringInvalidError**](/ko/reference/errors/action-query-string-invalid-error/)<br/>양식에서 잘못된 Action 쿼리 문자열을 전달했습니다.
- [**ActionCalledFromServerError**](/ko/reference/errors/action-called-from-server-error/)<br/>서버에서 예기치 않은 액션이 호출되었습니다.
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
title: Action unexpected called from the server.
i18nReady: true
githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/errors/errors-data.ts
---

> **ActionCalledFromServerError**: Action called from a server page or endpoint without using `Astro.callAction()`.
## 무엇이 잘못되었나요?
`Astro.callAction()`을 사용하지 않고 서버 페이지 또는 엔드포인트에서 호출된 액션입니다.
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
title: An invalid Action query string was passed by a form.
i18nReady: true
githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/errors/errors-data.ts
---

> **ActionQueryStringInvalidError**: The server received the query string `?_astroAction=ACTION_NAME`, but could not find an action with that name. If you changed an action's name in development, remove this query param from your URL and refresh.
## 무엇이 잘못되었나요?
서버가 쿼리 문자열 `?_astroAction=name`을 수신했지만 해당 이름의 액션을 찾을 수 없습니다. 액션 함수의 `.queryString` 속성을 사용하여 양식의 `action` URL을 검색하세요.

**더 보기:**
- [Actions RFC](https://github.com/withastro/roadmap/blob/actions/proposals/0046-actions.md)
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
---
title: An invalid Action query string was passed by a form.
i18nReady: true
githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/errors/errors-data.ts
---

> **ActionsUsedWithForGetError**: Action ACTION_NAME was called from a form using a GET request, but only POST requests are supported. This often occurs if `method="POST"` is missing on the form.
## 무엇이 잘못되었나요?
액션은 POST 요청만 지원하지만, 양식에서 GET 요청을 사용하여 호출되었습니다. 이 문제는 양식에 `method="POST"`가 누락된 경우에 자주 발생합니다.

**더 보기:**
- [Actions RFC](https://github.com/withastro/roadmap/blob/actions/proposals/0046-actions.md)
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ i18nReady: true
githubURL: https://github.com/withastro/astro/blob/main/packages/astro/src/core/errors/errors-data.ts
---

:::caution[더 이상 사용되지 않음]
이 오류는 Astro에서 더 이상 발생하지 않습니다.
:::

> **RewriteEncounteredAnError**: The route ROUTE that you tried to render doesn't exist, or it emitted an error during the rendering phase. STACK ? STACK : ''.
## 무엇이 잘못되었나요?
사용자가 존재하지 않는 경로를 사용하여 리라이트하려고 했거나 렌더링 단계에서 런타임 오류가 발생했습니다.



사용자가 존재하지 않는 경로를 사용하여 리라이트하려고 했거나 렌더링 단계에서 런타임 오류가 발생했습니다.
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,4 @@ Astro.rewrite("/target")

**더 보기:**
- [Request.clone()](https://developer.mozilla.org/en-US/docs/Web/API/Request/clone)
- [Astro.rewrite](/ko/reference/configuration-reference/#experimentalrewriting)


- [Astro.rewrite](/ko/reference/api-reference/#astrorewrite)

0 comments on commit 8189937

Please sign in to comment.