Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions src/content/docs/ko/guides/prefetch.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ i18nReady: true

`prefetch` 구성을 사용하여 프리페치를 활성화할 수 있습니다.

```js title="astro.config.js" ins={4}
```js title="astro.config.mjs" ins={4}
import { defineConfig } from 'astro/config';

export default defineConfig({
Expand Down Expand Up @@ -53,9 +53,9 @@ Astro는 다양한 사용 사례에 대해 4가지 프리페치 전략을 지원

### 기본 프리페치 전략

`data-astro-prefetch` 속성을 추가할 때 기본 프리페치 전략은 `hover`입니다. 이를 변경하려면 `astro.config.js` 파일에서 [`prefetch.defaultStrategy`](/ko/reference/configuration-reference/#prefetchdefaultstrategy)를 구성하면 됩니다.
`data-astro-prefetch` 속성을 추가할 때 기본 프리페치 전략은 `hover`입니다. 이를 변경하려면 `astro.config.mjs` 파일에서 [`prefetch.defaultStrategy`](/ko/reference/configuration-reference/#prefetchdefaultstrategy)를 구성하면 됩니다.

```js title="astro.config.js" ins={4-6}
```js title="astro.config.mjs" ins={4-6}
import { defineConfig } from 'astro/config';

export default defineConfig({
Expand All @@ -69,7 +69,7 @@ export default defineConfig({

`data-astro-prefetch` 속성이 없는 링크를 포함하여 모든 링크를 프리페치하려면, [`prefetch.prefetchAll`](/ko/reference/configuration-reference/#prefetchprefetchall)을 `true`로 설정하면 됩니다.

```js title="astro.config.js" ins={4-6}
```js title="astro.config.mjs" ins={4-6}
import { defineConfig } from 'astro/config';

export default defineConfig({
Expand Down Expand Up @@ -130,9 +130,9 @@ prefetch('/about', { ignoreSlowConnection: true });

페이지에서 [View Transitions](/ko/guides/view-transitions/)를 사용하면 기본적으로 프리페치도 활성화됩니다. 페이지에서 [모든 링크에 대한 프리페칭](#모든-링크에-대한-프리페치를-기본값으로-설정하기)을 활성화하는 `{ prefetchAll: true }`의 기본 구성을 설정합니다.

`astro.config.js`에서 프리페치 구성을 맞춤설정하여 기본값을 재정의할 수 있습니다. 예를 들어:
`astro.config.mjs`에서 프리페치 구성을 맞춤설정하여 기본값을 재정의할 수 있습니다. 예를 들어:

```js title="astro.config.js"
```js title="astro.config.mjs"
import { defineConfig } from 'astro/config';

export default defineConfig({
Expand All @@ -141,7 +141,7 @@ export default defineConfig({
})
```

```js title="astro.config.js"
```js title="astro.config.mjs"
import { defineConfig } from 'astro/config';

export default defineConfig({
Expand All @@ -156,9 +156,9 @@ export default defineConfig({

`@astrojs/prefetch` 통합은 v3.5.0에서 더 이상 사용되지 않으며 결국 완전히 제거될 예정입니다. 이 통합을 대체하는 Astro의 내장 프리페칭으로 마이그레이션하려면 다음 지침을 따르세요.

1. `@astrojs/prefetch` 통합을 제거하고 `astro.config.js`에서 `prefetch` 구성을 활성화합니다.
1. `@astrojs/prefetch` 통합을 제거하고 `astro.config.mjs`에서 `prefetch` 구성을 활성화합니다.

```js title="astro.config.js" ins={6} del={2,5}
```js title="astro.config.mjs" ins={6} del={2,5}
import { defineConfig } from 'astro/config';
import prefetch from '@astrojs/prefetch';

Expand Down