Moving Components

To move a component you can use the bit move command. This command will move the component from the current directory to the new directory.

Move a component to a different directory

bit move ui/my-component design/my-component
CopiedCopy
tip

This will only affect how your components are ordered in your workspace and not in your .bitmap file. If you want to move a component to a different namespace you will need to first remove it and then add it again with the correct namespace.

Moving components between repositories

Components can be migrated between different repositories with ease.

In the origin repository, eject the component to be used as an external dependency.

$ bit eject teambit.design/ui/buttons/button
CopiedCopy

Then, import the component into the target repository.

$ bit import teambit.design/ui/buttons/button
CopiedCopy

Looking for renaming components?

Head over to renaming components on the components' learning section.