diff --git a/packages/taro-mini-runner/src/webpack/build.conf.ts b/packages/taro-mini-runner/src/webpack/build.conf.ts index 3a5dfe2afc7b..e013ed0edaf5 100644 --- a/packages/taro-mini-runner/src/webpack/build.conf.ts +++ b/packages/taro-mini-runner/src/webpack/build.conf.ts @@ -163,7 +163,8 @@ export default (appPath: string, mode, config: Partial): any => { document: ['@tarojs/runtime', 'document'], navigator: ['@tarojs/runtime', 'navigator'], requestAnimationFrame: ['@tarojs/runtime', 'requestAnimationFrame'], - cancelAnimationFrame: ['@tarojs/runtime', 'cancelAnimationFrame'] + cancelAnimationFrame: ['@tarojs/runtime', 'cancelAnimationFrame'], + Element: ['@tarojs/runtime', 'TaroElement'] }) const isCssoEnabled = !((csso && csso.enable === false))