📦 Build React Typescript components in isolated environment

bit components GitHub license

This is a demo project for building components locally in isolated environment using Bit.
You can read the post here.

👾 Using Bit to virtually isolated components

  • Install and Initialize Bit: npm install bit-bin -g
  • Initialize Bit workspace: bit init
  • Track all the components: bit add src/components/*
  • Import the relevant compiler: bit import bit.envs/compilers/typescript --compiler
  • Build all the components in an isolated environment: bit build

🚀 Export the components to bit.dev so they can be easily shared between projects

  • Create a collection in bit.dev
  • Build and tag the tracked components: bit ag -a 1.0.0
  • Export them to the collection you just created: bit export <username>.<collection>
  • Now you can install your components in other projects and modify them locally using Bit.

🍾 Final result - components are fully reusable

You can see here the collection I created for exporting the components.

📖 Read the full post to understand better this repository.
You can read the post here.