-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
[#131] docs: pages directory > transpilePackages 추가
- Loading branch information
1 parent
854a864
commit 4074c16
Showing
1 changed file
with
25 additions
and
0 deletions.
There are no files selected for viewing
25 changes: 25 additions & 0 deletions
25
pages/docs/pages/api-reference/next-config-js/transpilePackages.mdx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- | ||
title: transpilePackages | ||
description: Automatically transpile and bundle dependencies from local packages (like monorepos) or from external dependencies (`node_modules`). | ||
--- | ||
|
||
{/* 이 문서의 내용은 App Router와 Pages Router에서 공유됩니다. Pages Router에만 해당하는 내용을 추가하려면 `<PagesOnly>내용</PagesOnly>` 컴포넌트를 사용할 수 있습니다. 공유된 내용은 컴포넌트로 감싸지 않아야 합니다. */} | ||
|
||
# transpilePackages | ||
|
||
Next.js는 로컬 패키지(모노레포와 같은) 또는 외부 종속성(`node_modules`)에서 종속성을 자동으로 트랜스파일하고 번들링할 수 있습니다. 이는 `next-transpile-modules` 패키지를 대체합니다. | ||
|
||
```js filename="next.config.js" | ||
/** @type {import('next').NextConfig} */ | ||
const nextConfig = { | ||
transpilePackages: ['package-name'], | ||
} | ||
|
||
module.exports = nextConfig | ||
``` | ||
|
||
## Version History | ||
|
||
| Version | Changes | | ||
| --------- | --------------------------- | | ||
| `v13.0.0` | `transpilePackages` 추가됨. | |