Skip to content

Commit

Permalink
Document the bundler-args argument
Browse files Browse the repository at this point in the history
  • Loading branch information
TristanCacqueray committed Jan 14, 2024
1 parent b450892 commit 934df50
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -952,6 +952,19 @@ $ node -e "import('./index.js').then(m => console.log(m.main))"
[Function]
```

If the build fails with `✘ [ERROR] Could not resolve "better-sqlite3"`, you can pass extra arguments to esbuild with:

- the `bundler-args` argument, for example: `--bundler-args "--external:better-sqlite3"`.

… or by using the following configuration:

```yaml
package:
bundle:
extra_args:
- "--external:better-sqlite3"
```

### Enable source maps

When bundling, you can include `--source-maps` to generate a final source map for your bundle.
Expand Down

0 comments on commit 934df50

Please sign in to comment.