The Wire · Showcase
VUE LANGUAGE TOOLS REWRITES TEMPLATE BINDING ENGINE
By RepoJournal · Filed · About Vue.js
Vue's language server drops two legacy codegen systems overnight, changing how every template ref resolves.
Johnson Chu landed a long-planned refactor in vuejs/language-tools [1] that removes `linkedCodeMap` and `__VLS_SetupExposed`, cutting legacy machinery that has quietly complicated template type-checking for years. Setup bindings in generated code now compile to direct `binding.value` references, backed by a `__VLS_withDotValue` guard that adds a shallow `.value` accessor to non-ref bindings, a change the PR notes also affects `useTemplateRef` [2]. The same author pushed a follow-up fix [3] to stop token-boundary double-mapping, which previously corrupted renames like `foo` at the `:[foo]` edge into a spurious `Ref.value` reference in `@vue/reactivity`. On the compiler-vapor side, zhiyuanzmj shipped two fixes [4] [5]: one preserves dynamic v-for slot state, the other propagates component roots through `Transition`, both needed for the experimental Vapor mode to keep pace with the main compiler. With only 4 commits and 2 PRs in the last 24 hours, this is tight, surgical maintenance, not a feature dump: the language-core refactor is the one to watch for IDE regressions, while the Vapor patches signal that the compiler team is actively hardening edge cases.
One email a day. Unsubscribe in one click.
Keep up with Vue.js in about 3 minutes a day: what actually shipped — the commits, pull requests, releases, and security advisories that matter.
One email a day. Unsubscribe in one click. Read a past issue →
Action items
- → Update vue-tsc and Volar to the latest language-tools nightly and run a template rename smoke test, especially around refs in array syntax vuejs/language-tools [immediate]
- → If you track Vapor mode, pull vue-jsx-vapor and verify dynamic v-for slots still render correctly after the state-preservation fix vuejs/vue-jsx-vapor [plan]
References
- [1] refactor(language-core): remove linkedCodeMap and __VLS_SetupExposed ↗ vuejs/language-tools
- [2] refactor(language-core): remove linkedCodeMap and __VLS_SetupExposed (#6175) vuejs/language-tools
- [3] fix(language-core): prevent template token boundary double-mapping ↗ vuejs/language-tools
- [4] fix(vapor): preserve dynamic v-for slot state- #15280 vuejs/vue-jsx-vapor
- [5] fix(compiler-vapor): propagate component root through Transition vuejs/vue-jsx-vapor