Remove the unused @gitlab/vue-virtual-scroller-vue3 dependency
Problem
package.json declares a dependency that nothing imports, and its name does not match what it installs.
"@gitlab/vue-virtual-scroller-vue3": "npm:vue-virtual-scroller@1.1.2",The name says vue3. The package it installs is vue-virtual-scroller@1.1.2, which is the latest release of the Vue 2 line, with peerDependencies.vue of ^2.6.11.
Evidence
package.json:76declares it.yarn.lock:1533resolves it tovue-virtual-scroller-1.1.2.tgz.node_modules/@gitlab/vue-virtual-scroller-vue3/package.jsonreports version1.1.2and peervue ^2.6.11.- No file in the repository imports
@gitlab/vue-virtual-scroller-vue3. The only other match for that string isconfig/helpers/context_aliases_shared.js:17, which points at the vendored directoryvendor/assets/javascripts/vue-virtual-scroller-vue3/src/index.js. That is a different thing that happens to share the suffix.
Why it is confusing
The entry sits next to three aliases that are real and are used:
"@gitlab/vue-router-vue3": "npm:vue-router@4.5.1",
"@gitlab/vuedraggable-vue3": "npm:vuedraggable@4.0.1",
"@gitlab/vuex-vue3": "npm:vuex@4.1.0",Those follow the pattern of aliasing the Vue 3 major of a package. This one does not. Read quickly, it suggests the Vue 3 build of the scroller comes from npm, when it actually comes from the vendored directory.
It was added in e90f862b, the same commit that vendored the 2.x source. I have not established what it was meant to do.
Proposal
Remove the entry from package.json and regenerate yarn.lock.
Confirm first that no build config references it. config/helpers/aliases.js and config/helpers/context_aliases_shared.js both point at the vendored path, not the npm name.
Related
- Scroller compatibility defect: #619357 (closed)