文章全局事件

v2
king 1 year ago
parent c2b9a4812f
commit 84fbd98fa9
  1. 9
      src/components/articlesBox/articlesBox.tsx

@ -30,6 +30,15 @@ const ArticlesBox: FC<Props> = (props) => {
articlesEvent.off(data.id)
})
Taro.useDidShow(()=>{
articlesEvent.recordsOn(data.id, ({view}) => {
setData({
...data,
page_view: view
})
})
})
const toArticlePage = () => {
Taro.navigateTo({
url: `/pages/preview/brand/article/article?id=${data.id}`

Loading…
Cancel
Save