Minimizing bundle size
The following packages exports multiple components:
The default entry point for the previous packages includes CSS for all of its component. You have two options to reduce the bundle size:
Option 1: Use path imports
Option 2: Use babel
with babel-plugin-import
-
Setup
babel
in your project. -
Install
babel-plugin-import
: -
Create a
.babelrc.js
in the root directory of your project. -
Setup
babel-plugin-import
in your.babelrc.js
file:Manual Setup
Automatic Setup with
@hrc/babel-config
-
Install
@hrc/babel-config
: -
Write the following code in your
.babelrc.js
file:
-