import transform component apache/echarts#15514
diff --git a/common/buildCode.js b/common/buildCode.js
index 2274157..f484c78 100644
--- a/common/buildCode.js
+++ b/common/buildCode.js
@@ -190,6 +190,14 @@
deps.push('UniversalTransition');
}
});
+ // Dataset transform
+ if (option.dataset && Array.isArray(option.dataset)) {
+ option.dataset.forEach((dataset) => {
+ if (dataset.transform) {
+ deps.push('TransformComponent');
+ }
+ });
+ }
// Remove duplicates
return Array.from(new Set(deps));
@@ -215,6 +223,10 @@
if (includeType) {
componentsImports.push(dep.replace(/Component$/, 'ComponentOption'));
}
+ } else if (dep === 'TransformComponent') {
+ // TransformComponent don't have individual option type.
+ // TODO will put in to an config if there are other similar components
+ componentsImports.push(dep);
} else if (CHARTS_GL_MAP_REVERSE[dep]) {
chartsGLImports.push(dep);
} else if (COMPONENTS_GL_MAP_REVERSE[dep]) {