Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
b9812ef
docs: Add Turborepo 2.10 release post and update docs
anthonyshew Jun 16, 2026
4f7b6cb
docs: Rename cache eviction headliner to Local cache eviction
anthonyshew Jun 16, 2026
ff24329
docs: Rename affected/filter headliner to Combine
anthonyshew Jun 16, 2026
ae91bc9
docs: Capitalize Just In Time in JIT headliner
anthonyshew Jun 16, 2026
f4944f1
docs: Remove Node.js shim paragraph from 2.10 post
anthonyshew Jun 16, 2026
baf98f4
docs: Hyphenate Just-In-Time in JIT documentation
anthonyshew Jun 16, 2026
82f048c
WIP d28eb
anthonyshew Jun 16, 2026
b993cf2
Merge branch 'main' of https://github.com/vercel/turborepo into docs/…
anthonyshew Jun 17, 2026
be313a0
WIP c1bf4
anthonyshew Jun 17, 2026
593dda0
Update apps/docs/content/blog/2-10.mdx
anthonyshew Jun 17, 2026
a86a3db
WIP 43ad5
anthonyshew Jun 17, 2026
c975a7f
WIP bb8c1
anthonyshew Jun 17, 2026
ba9aadc
docs: Update deferred hashing docs for structured inputs API
cursoragent Jun 23, 2026
2589a30
docs: Remove local cache eviction section from caching guide
cursoragent Jun 23, 2026
4efaa70
docs: Remove graceful shutdown section from run reference
cursoragent Jun 23, 2026
3e7ee98
docs: Simplify deferred hashing examples to jit and dependencyOutputs
cursoragent Jun 23, 2026
2e00f20
docs: Update 2.10 release accordions and contributor list
cursoragent Jun 23, 2026
a8bbf39
docs: Remove dead graceful shutdown link from 2.10 post
cursoragent Jun 23, 2026
8b2cb7f
WIP d9d52
anthonyshew Jun 24, 2026
d1a18f0
WIP b6d30
anthonyshew Jun 24, 2026
174da0f
Update apps/docs/content/blog/2-10.mdx
anthonyshew Jun 24, 2026
3376096
docs: Re-align 2.10 reference docs with release post
anthonyshew Jun 24, 2026
a36e8e2
docs: Rewrite deferred hashing as reference documentation
anthonyshew Jun 24, 2026
33324cd
WIP 3d13c
anthonyshew Jun 24, 2026
90e6a51
Update apps/docs/content/blog/2-10.mdx
anthonyshew Jun 24, 2026
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
591 changes: 591 additions & 0 deletions apps/docs/content/blog/2-10.mdx

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -230,9 +230,12 @@ For this reason, you can use the `$TURBO_DEFAULT$` microsyntax to fine-tune the

In this task definition, Turborepo will use the default `inputs` behavior for the `build` task, but will ignore changes to the `README.md` file. If the `README.md` file is changed, the task will still hit cache.

#### Deferred hashing <ExperimentalBadge>Pre-release</ExperimentalBadge>
#### Deferred hashing

Some tasks need to hash files that are created by another task in the same run.Use [`mode: "jit"` or `mode: "dependencyOutputs"`](/docs/reference/configuration#deferred-hashing) to wait until the task's dependencies have completed before finalizing the cache key.
Some tasks need to hash files that are created by another task in the same run.
Use structured [`inputs`](/docs/reference/configuration#deferred-hashing) with
`mode: "jit"` or `mode: "dependencyOutputs"` to defer hashing until the task's
dependencies have completed.

### Registering Root Tasks

Expand Down
95 changes: 27 additions & 68 deletions apps/docs/content/docs/reference/configuration.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ Specify the filesystem cache directory.

Default: `"0"` (disabled)

Maximum age of local cache entries before automatic eviction. Entries older than this value are removed at the start of each `turbo run`.
Maximum age of local cache entries before automatic eviction. Entries older than this value are removed when eviction runs at the start of each `turbo run`. Eviction runs in a background thread so it does not block tasks.

```jsonc title="./turbo.json"
{
Expand All @@ -197,6 +197,11 @@ Accepts a human-readable duration string with the following units:

Set to `"0"` to disable age-based eviction.

<Callout type="info">
Local cache eviction is opt-in today. We expect to enable it by default in
Turborepo 3.0.
</Callout>

<Callout type="info">
You may also set this option via the
[`TURBO_CACHE_MAX_AGE`](/docs/reference/system-environment-variables#turbo_cache_max_age)
Expand All @@ -207,7 +212,7 @@ Set to `"0"` to disable age-based eviction.

Default: `"0"` (disabled)

Maximum total size of the local filesystem cache. When the cache exceeds this limit, the oldest entries are evicted until the cache is within the limit.
Maximum total size of the local filesystem cache. When the cache exceeds this limit, the oldest entries are evicted until the cache is within the limit. Eviction runs in a background thread at the start of each `turbo run`, so it does not block tasks.

```jsonc title="./turbo.json"
{
Expand Down Expand Up @@ -863,65 +868,28 @@ Starting a file glob with `$TURBO_ROOT$` will change the glob to be relative to
}
```

#### Deferred hashing <ExperimentalBadge>Pre-release</ExperimentalBadge>

Deferred hashing is a feature for tasks whose cache key depends on
files that are not reliable when `turbo` starts up. This commonly happens when a
task consumes generated code, generated CSS, API types, or other files
materialized by an earlier task in the same run.

<Callout type="warn" title="Pre-release">
Deferred hashing is a pre-release feature. The configuration surface and
`--dry` output may change before this feature is marked stable.
</Callout>

Most tasks should continue using normal string `inputs`. Use deferred hashing only when startup hashing would read missing or stale files.
#### Deferred hashing

Deferred hashing uses structured `inputs` objects. Available modes:
`inputs` entries can be structured objects that defer file hashing until after
the task's dependencies have completed. Tasks that depend on a deferred task are
also deferred until upstream hashes are available.

| Mode | What it does |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `startup` | Hashes files before the task graph starts executing. This is equivalent to normal string inputs, but useful when pairing normal inputs with deferred inputs. |
| `jit` | Defers hashing until after the task's `dependsOn` tasks complete, just before this task checks cache. |
| `dependencyOutputs` | Defers hashing of declared `outputs` from selected dependency tasks until after those tasks complete. |
##### `mode: "jit"`

Use `startup` to describe the non-deferred part of the cache key:

```jsonc title="./turbo.json"
{
"tasks": {
"build": {
"inputs": [
{
"mode": "startup",
"withDefaults": true,
"globs": ["!dist/**"],
},
],
"outputs": ["dist/**"],
},
},
}
```

In this example, `build` still hashes at startup, using the default package inputs while excluding `dist/**`.

Use `jit` when this task should hash files after another task creates or updates them:
Hash the files matching `globs` just before the task executes, after its
dependencies have completed.

```jsonc title="./turbo.json"
{
"tasks": {
"codegen": {
"outputs": ["src/generated/**"],
"cache": false,
},
"check-types": {
"build": {
"dependsOn": ["codegen"],
"inputs": [
{
"mode": "startup",
"withDefaults": true,
"globs": ["!src/generated/**"],
},
"$TURBO_DEFAULT$",
"!src/generated/**",
{
"mode": "jit",
"globs": ["src/generated/**"],
Expand All @@ -932,40 +900,31 @@ Use `jit` when this task should hash files after another task creates or updates
}
```

In this example, `check-types` excludes generated files from startup hashing, waits for `codegen`, then hashes `src/generated/**` before checking cache.
##### `mode: "dependencyOutputs"`

Use `dependencyOutputs` when this task should hash declared outputs from a task dependency instead of arbitrary files in its own package:
Hash the intersection of a dependency's declared `outputs` and `globs`.
`dependencyOutputs` does not create task graph edges; selected tasks must
already be present through `dependsOn`.

```jsonc title="./turbo.json"
{
"tasks": {
"codegen": {
"outputs": ["src/generated/**"],
},
"check-types": {
"dependsOn": ["codegen"],
"dependsOn": ["^check-types"],
"outputs": ["dist/**"],
"inputs": [
{
"mode": "startup",
"withDefaults": true,
"globs": ["!src/generated/**"],
},
"$TURBO_DEFAULT$",
{
"mode": "dependencyOutputs",
"from": ["codegen"],
"globs": ["src/generated/**"],
"globs": ["dist/**/*.d.ts"],
"from": ["^check-types"],
},
],
},
},
}
```

In this example, `check-types` hashes the files that `codegen` declares in `outputs` and that also match `src/generated/**`. `dependencyOutputs` does not create task graph edges; the selected task must already be present through `dependsOn`.

Notes:

- `withDefaults` is only valid with `startup` and `jit`.
- `from` is only valid with `dependencyOutputs`.
- `dependencyOutputs.from` defaults to the task's direct task dependencies.
- A selected `dependencyOutputs` task must declare `outputs`.
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/next-env.d.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
import "./.next/types/routes.d.ts";
import "./.next/dev/types/routes.d.ts";

// NOTE: This file should not be edited
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
2 changes: 1 addition & 1 deletion apps/docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"lucide-react": "^0.555.0",
"motion": "^12.23.25",
"nanoid": "^5.1.6",
"next": "16.2.3",
"next": "16.2.9",
"next-themes": "^0.4.6",
"radix-ui": "latest",
"react": "^19.2.3",
Expand Down
Loading
Loading