You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The company I worked has a component library build on vue@2.6.x. But the problem is that the component library is not a standalone module. It's build by lots of dependencies.
Such as I have a package called xyz-table, dependencied xyz-util@latest. I have another package called xyz-tree also dependencied xyz-util@latest.
when I fixed a bug with xyz-util, the xyz-tree and xyz-table can auto update it.
However, to many packages like this, so we publish a package called xyz-collection which is dependencies all of the xyz-* package. so project could using like this:
importXyzUtilfrom'xyz-util';// ...
This is based on phantom dependency, I know it's not good but I have no idea to solve. (problem one)
The problem two is that people must using the last version. But as known as last version is not stable version, so too many production occured 😭😭😭.
And we still try to resolve problem two, so we write dependency xyz-collection and xyz-table as the same time.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
The company I worked has a component library build on vue@2.6.x. But the problem is that the component library is not a standalone module. It's build by lots of dependencies.
Such as I have a package called
xyz-table
, dependenciedxyz-util@latest
. I have another package calledxyz-tree
also dependenciedxyz-util@latest
.when I fixed a bug with
xyz-util
, thexyz-tree
andxyz-table
can auto update it.However, to many packages like this, so we publish a package called
xyz-collection
which is dependencies all of thexyz-*
package. so project could using like this:This is based on phantom dependency, I know it's not good but I have no idea to solve. (problem one)
The problem two is that people must using the last version. But as known as last version is not stable version, so too many production occured 😭😭😭.
And we still try to resolve problem two, so we write dependency
xyz-collection
andxyz-table
as the same time.a package.json file such as this:
the table@1.4.9 dependency util@2.0.0
but collection@1.5.0 dependency util@1.5.1
however, we cannot judge the two version which will be flated to node_modules, so bug is also exist...😭
Could your have some suggest for me, or some good idea to solve this problem?
I'm looking forward to your answer.
By the way, this is my first question, if I have some errors about grammar or expression, thank your for your point it. Good luck!
Beta Was this translation helpful? Give feedback.
All reactions