Open govind-srinidhi opened 1 year ago
Tried to make the current setup work with NPM before starting with YARN experimentation:
Here are the observations:
@storybook/vue-vite
in the root under packages/node_modules.vue-vite
and the storybook page was accessible for Vue 2.This is more of a maintenance hell, if we need to mimick nohoist feature every time we have to interact with new package. Makes this one of the primary reason to go away with NPM and start considering YARN or PNPM.
Feature description
There is a requirement for us to make Lume work for both Vue 2 and 3. In order to test the functionalities in both the version, we need to have two instances of storybook one to verify all the components in Vue 2 and the other for Vue 3.
We recently noticed an issue with
nohoist
not available in npm.nohoist
allows us to skip sharing the same package between the workspaces.Storybook for Vue 2 has a dependency of one version of
vue-vite
package and Vue 3's storybook needs a different dependency ofvue-vite
.With the existing hoisting algorithm, npm is picking the shared version of
vue-vite
always rather than the Vue 2 or 3 specific workspace'svue-vite
. This can be easily solved withnohoist
feature that's available in other package managers likeyarn
andpnpm
.Goal of this task is to:
nohoist
feature ourselves. Maybe something like this?nohoist
feature by default. That could solve the problem, and since it's a widely used package manager worth checking outProblem/motivation
No response
Describe alternatives you've considered
No response
Additional context
No response
Validations