Skip to content

Commit 847ddd7

Browse files
committed
docs: update info
1 parent 0d2c804 commit 847ddd7

File tree

1 file changed

+14
-3
lines changed

1 file changed

+14
-3
lines changed

README.md

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -271,8 +271,6 @@ Specifies the module IDs or regular expressions that match module IDs to be trea
271271

272272
The IDs and regular expressions provided in this option are applied globally across all entries.
273273

274-
Alternatively, externals can be defined individually for each entry using the `entry.externals` property.
275-
276274
```ts
277275
// bundler.config.ts
278276

@@ -283,6 +281,19 @@ export default defineConfig({
283281
})
284282
```
285283

284+
Alternatively, externals can be defined individually for each entry using the `entry.externals` property.
285+
286+
```ts
287+
export default defineConfig({
288+
entries: [
289+
{
290+
input: './src/index.ts',
291+
externals: ['id-1', 'id-2', /regexp/],
292+
},
293+
],
294+
})
295+
```
296+
286297
### minify
287298

288299
- Type: `boolean`
@@ -300,7 +311,7 @@ export default defineConfig({
300311
})
301312
```
302313

303-
It can also be set per entry.
314+
It can also be set per entry:
304315

305316
```ts
306317
export default defineConfig({

0 commit comments

Comments
 (0)