You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by sh...@apache.org on 2020/11/06 03:08:44 UTC

[incubator-echarts] branch bundle-dts updated: fix(types): include zrender in the bundled ts

This is an automated email from the ASF dual-hosted git repository.

shenyi pushed a commit to branch bundle-dts
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git


The following commit(s) were added to refs/heads/bundle-dts by this push:
     new 3b5da09  fix(types): include zrender in the bundled ts
3b5da09 is described below

commit 3b5da094e78a1ef5e2ead276afc1993f9b2f5cc8
Author: pissang <bm...@gmail.com>
AuthorDate: Fri Nov 6 11:08:03 2020 +0800

    fix(types): include zrender in the bundled ts
---
 build/pre-publish.js | 6 +++++-
 index.d.ts           | 6 +++++-
 2 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/build/pre-publish.js b/build/pre-publish.js
index 29982e7..ce14e6a 100644
--- a/build/pre-publish.js
+++ b/build/pre-publish.js
@@ -390,7 +390,11 @@ async function readFilePaths({patterns, cwd}) {
 async function bundleDTS() {
     const bundle = await rollup.rollup({
         input: nodePath.resolve(__dirname, '../index.d.ts'),
-        plugins: [dts()]
+        plugins: [
+            dts({
+                respectExternal: true
+            })
+        ]
     });
     await bundle.write({
         file: nodePath.resolve(__dirname, '../types/dist/echarts.d.ts')
diff --git a/index.d.ts b/index.d.ts
index fb3704e..1631f31 100644
--- a/index.d.ts
+++ b/index.d.ts
@@ -22,6 +22,10 @@
 /// Make sure run it before edit this file.                         ///
 ///////////////////////////////////////////////////////////////////////
 
-export * from './types/src/echarts.all';
+// Restrict exports
+export {
+    init, connect, disConnect, dispose, getInstanceByDom, getInstanceById,
+    registerMap, registerLocale, getMap, registerTheme
+} from './types/src/echarts.all';
 
 export {EChartsFullOption as EChartsOption} from './types/src/option';
\ No newline at end of file


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org