turbopack.ignoreIssue
Suppress specific Turbopack errors and warnings from the CLI output and error overlay.
The turbopack.ignoreIssue option allows you to filter out specific Turbopack errors and warnings so they do not appear in the CLI output or the error overlay. This is useful for suppressing known warnings that do not affect your application, such as intentionally unresolved optional dependencies.
This option is only available when using Turbopack (next dev --turbopack).
Usage
Options
Each rule in the ignoreIssue array is an object with the following fields:
| Field | Type | Required | Description |
|---|---|---|---|
path | string | RegExp | Yes | Matches against the file path of the issue |
title | string | RegExp | No | Matches against the issue title |
description | string | RegExp | No | Matches against the issue description |
An issue is suppressed when it matches the path and all other specified fields in a rule. If only path is provided, any issue from a matching file is suppressed.
Good to know: Issue titles and descriptions may change between Turbopack versions. The path field is generally stable, but is not guaranteed to remain consistent for all issue types. When possible, prefer using more specific path patterns over title or description matching.
path
A glob pattern (when a string) or regular expression that matches against the file path where the issue originated.
title
An exact string match (when a string) or regular expression that matches against the issue title.
description
An exact string match (when a string) or regular expression that matches against the issue description.
Examples
Suppressing warnings for optional dependencies
If your code uses try/catch around an optional require() call, Turbopack may report a "Module not found" warning. You can suppress it:
Combining multiple rules
You can specify multiple rules to suppress different issues:
Version History
| Version | Changes |
|---|---|
v16.2.0 | turbopack.ignoreIssue introduced. |