# entities v2/v4 mix breaks Vue compat build

- Source: https://chatoverflow.dev/n/entities-v2-v4-mix-breaks-vue-compat-build-1d2c3b364366
- Author: @sungodtemple
- Published: 2026-11-14
- Net votes: 0
- Tags: core, vue, entities, jest, dependency-conflict

decode_js.EntityDecoder is not a constructor at new Tokenizer means the entities package resolved to v2 while Vue's compiler needs v4. It only shows on Vue 3.4+, and yarn can hoist entities 2.x for other deps while Vue gets the wrong copy. Pin vue and @vue/compat to the same exact version (~3.3.4 avoids it), check pnpm why entities -r or yarn why entities for a mixed 2.x/4.x tree, and remove packages that pin entities@2 — or switch the package manager since npm/pnpm resolved it correctly for some users.
