🎉
Welcome to Bit's new open-source website!

Forking Components

When you fork a component from a remote scope, you create a copy of it in your workspace. This copy is defined as 'new', and has no previous versions. The scope of that copied component is set, by default, to your workspace default scope (defined in the defaultScope property).

Run the following to fork a component:

$bit
Copiedcopy

For example, the following command forks teambit.design/basic/button to your workspace:

$bit
Copiedcopy

Run the following to fork a component and change its scope to a scope different than your workspace default scope:

$bit
Copiedcopy

Refactoring

Use the --refactor option to update the import statements in all dependent components (in the same workspace). For example:

$bit
Copiedcopy

All occurrences of import { Button } from '@teambit/design.basic.button' are now replaced by import { Button } from '@my-org/my-scope.basic.button'.

next

Installing Components

Components once exported to a remote scope can be consumed in any other project/app with the package manager of your choice.

Continue
on this page
Refactoring