Skip to main content
Version: 4.0 (Current)

Helpers

getImportPluginsOfRsuite

Used with babel-plugin-import to manually recover tree-shaking behavior when automatic splitting is not enough.

This helper ships with built-in behavior for rsuite.

Usage

import { defineConfig, getImportPluginsOfRsuite } from '@dz-web/esboot';

export default defineConfig((runtimeCfg) => ({
extraBabelPlugins: [getImportPluginsOfRsuite()],
}));

API

type GetImportPluginsOfRsuite = (noCssCompList?: string[]) => BabelPlugin;

noCssCompList is used for components that do not ship styles.