Skip to content

Commit

Permalink
fix(taro-h5): 补全 taro-h5 导出的散装 API, fix #8189
Browse files Browse the repository at this point in the history
  • Loading branch information
Chen-jj committed Dec 3, 2020
1 parent c061e07 commit cd7b90a
Showing 1 changed file with 68 additions and 4 deletions.
72 changes: 68 additions & 4 deletions packages/taro-h5/src/taro/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,31 @@ const {
render,
interceptors,
Current,
...rest
noPromiseApis,
onAndSyncApis,
otherApis,
Link,
getCurrentInstance,
useDidShow,
useDidHide,
usePullDownRefresh,
useReachBottom,
usePageScroll,
useResize,
useShareAppMessage,
useTabItemTap,
useTitleClick,
useOptionMenuClick,
usePullIntercept,
useShareTimeline,
useAddToFavorites,
useReady,
useRouter,
options,
nextTick
} = Taro

const taro = {
...rest,
getEnv,
ENV_TYPE,
Events,
Expand All @@ -29,7 +49,29 @@ const taro = {
reLaunch,
redirectTo,
getCurrentPages,
switchTab
switchTab,
noPromiseApis,
onAndSyncApis,
otherApis,
Link,
getCurrentInstance,
useDidShow,
useDidHide,
usePullDownRefresh,
useReachBottom,
usePageScroll,
useResize,
useShareAppMessage,
useTabItemTap,
useTitleClick,
useOptionMenuClick,
usePullIntercept,
useShareTimeline,
useAddToFavorites,
useReady,
useRouter,
options,
nextTick
}

const initPxTransform = originalInitPxTransform.bind(taro)
Expand Down Expand Up @@ -88,5 +130,27 @@ export {
reLaunch,
redirectTo,
getCurrentPages,
switchTab
switchTab,
noPromiseApis,
onAndSyncApis,
otherApis,
Link,
getCurrentInstance,
useDidShow,
useDidHide,
usePullDownRefresh,
useReachBottom,
usePageScroll,
useResize,
useShareAppMessage,
useTabItemTap,
useTitleClick,
useOptionMenuClick,
usePullIntercept,
useShareTimeline,
useAddToFavorites,
useReady,
useRouter,
options,
nextTick
}

0 comments on commit cd7b90a

Please sign in to comment.