teambit / envs

Component development environments for the Bit community
https://bit.dev/bit/envs
Other
63 stars 9 forks source link

package.json in dists has a different version than in src #85

Open davidfirst opened 4 years ago

davidfirst commented 4 years ago

Describe the bug

When tagging a component, Bit builds the component first then tags it. If for example, a component is at 0.0.1, during the build process, the compiler generates a package.json file with the version 0.0.1. The problem is that immediately after the build, the component is tagged to 0.0.2, which creates an inconsistency between the two. This was the reason for https://github.com/teambit/bit/issues/2260 issue.

Steps to Reproduce

  1. create a ts component, tag as 0.0.1, export,
  2. import to a new workspace.
  3. change the component and tag. Notice the difference between the package.json files.

Expected Behavior

Not sure. Why is there package.json in the dists directory in the first place?

Specifications

Additional context

Add any other context about the problem here.