Skip to content

fix(runtime-vapor): don't leak the dev-rendering parent into child setup - #16095

Merged
edison1105 merged 2 commits into
vuejs:minorfrom
ValentinYoushkevich:fix/vapor-dev-render-child-setup
Nov 3, 2026
Merged

edison1105 merged 2 commits into
vuejs:minorfrom
ValentinYoushkevich:fix/vapor-dev-render-child-setup

Conversation

@ValentinYoushkevich

Copy link
Copy Markdown
Contributor

In a dev build, a Vapor parent stays set as the current rendering instance (#14719) through the setup of every Vapor child it creates while rendering, so asset resolution in the child reads the parent. An inline-compiled (prebuilt) recursive component, like a tree item, rendered by a dev-compiled one gets the parent's type for its file-name self-reference and recurses until Maximum call stack size exceeded; an explicit name or a locally registered component fails to resolve. The same leak makes getCurrentInstance() in the child return the parent, while production returns null as the 3.6 notes describe.

setupComponent now clears the rendering instance for setup in dev; the child's own render sets it again.

Playground (getCurrentInstance() in a child: App in dev, null with PROD).

@coderabbitai

coderabbitai Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: ac7068d7-f3b7-4d54-8910-239e44388e6a

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Tip

🎯 Customize your risk assessments

Guide how CodeRabbit assesses merge risk and security architecture risk. Highlight sensitive changes and explain your security boundaries using Merge Risk Instructions and Security Risk Instructions in your review settings. Security architecture risk assessments require the Advanced plan or above.

✅ Automatic approvals, with your rules

Let CodeRabbit approve pull requests once required threads are resolved, pre-merge checks pass, and your risk limits are met. Enable Automatic approvals in review settings, with overrides for teams or file paths.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

CodeRabbit Verify

  • Run CodeRabbit Verify to test the changes in this pull request.

@netlify

netlify Bot commented Nov 2, 2026

Copy link
Copy Markdown

❌ Deploy Preview for vue-sfc-playground failed. Why did it fail? →

Name Link
🔨 Latest commit 169146d
🔍 Latest deploy log https://app.netlify.com/projects/vue-sfc-playground/deploys/6ae8727734d5399d2f77accc

@pkg-pr-new

pkg-pr-new Bot commented Nov 2, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

@vue/compiler-core

pnpm add https://pkg.pr.new/@vue/compiler-core@16095
npm i https://pkg.pr.new/@vue/compiler-core@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/compiler-dom

pnpm add https://pkg.pr.new/@vue/compiler-dom@16095
npm i https://pkg.pr.new/@vue/compiler-dom@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/compiler-sfc

pnpm add https://pkg.pr.new/@vue/compiler-sfc@16095
npm i https://pkg.pr.new/@vue/compiler-sfc@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/compiler-ssr

pnpm add https://pkg.pr.new/@vue/compiler-ssr@16095
npm i https://pkg.pr.new/@vue/compiler-ssr@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/compiler-vapor

pnpm add https://pkg.pr.new/@vue/compiler-vapor@16095
npm i https://pkg.pr.new/@vue/compiler-vapor@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/reactivity

pnpm add https://pkg.pr.new/@vue/reactivity@16095
npm i https://pkg.pr.new/@vue/reactivity@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/runtime-core

pnpm add https://pkg.pr.new/@vue/runtime-core@16095
npm i https://pkg.pr.new/@vue/runtime-core@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/runtime-dom

pnpm add https://pkg.pr.new/@vue/runtime-dom@16095
npm i https://pkg.pr.new/@vue/runtime-dom@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/runtime-vapor

pnpm add https://pkg.pr.new/@vue/runtime-vapor@16095
npm i https://pkg.pr.new/@vue/runtime-vapor@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/server-renderer

pnpm add https://pkg.pr.new/@vue/server-renderer@16095
npm i https://pkg.pr.new/@vue/server-renderer@16095
yarn add https://pkg.pr.new/@vue/[email protected]

@vue/shared

pnpm add https://pkg.pr.new/@vue/shared@16095
npm i https://pkg.pr.new/@vue/shared@16095
yarn add https://pkg.pr.new/@vue/[email protected]

vue

pnpm add https://pkg.pr.new/vue@16095
npm i https://pkg.pr.new/vue@16095
yarn add https://pkg.pr.new/[email protected]

@vue/compat

pnpm add https://pkg.pr.new/@vue/compat@16095
npm i https://pkg.pr.new/@vue/compat@16095
yarn add https://pkg.pr.new/@vue/[email protected]

commit: 21ccbaf

@github-actions

github-actions Bot commented Nov 2, 2026

Copy link
Copy Markdown

Size Report

Bundles

File Size Gzip Brotli
compiler-dom.global.prod.js 87.4 kB 30.7 kB 27 kB
runtime-dom.global.prod.js 121 kB 45.3 kB 40.6 kB
vue.global.prod.js 181 kB 65.6 kB 58.5 kB

Usages

Name Size Gzip Brotli
createApp (CAPI only) 53.9 kB 21 kB 19.1 kB
createApp 62.9 kB 24.3 kB 22.1 kB
createApp + vaporInteropPlugin 118 kB 43 kB 38.7 kB
createVaporApp 34.2 kB 13.2 kB 12.2 kB
createSSRApp 67.8 kB 26.3 kB 23.8 kB
createVaporSSRApp 42 kB 16 kB 14.8 kB
defineCustomElement 69.5 kB 26.3 kB 23.9 kB
defineVaporCustomElement 49.1 kB 18 kB 16.5 kB
overall 78.4 kB 29.8 kB 27 kB

@edison1105 edison1105 added the scope: vapor related to vapor mode label Nov 3, 2026
@edison1105
edison1105 merged commit 21fec4e into vuejs:minor Nov 3, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope: vapor related to vapor mode

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants