Commit c55866c5 by zhangleyuan

feat:处理opendata的显示问题

parent 1ede3ebf
...@@ -2,8 +2,8 @@ import React, { useRef, useLayoutEffect } from 'react' ...@@ -2,8 +2,8 @@ import React, { useRef, useLayoutEffect } from 'react'
export default function WWOpenDataCom({ type, openid }) { export default function WWOpenDataCom({ type, openid }) {
const ref = useRef(null) const ref = useRef(null)
useLayoutEffect(() => { useLayoutEffect(() => {
console.log(WWOpenData) console.log(window.WWOpenData)
WWOpenData && WWOpenData.bind(ref.current) window.WWOpenData && window.WWOpenData.bind(ref.current)
}) })
return <ww-open-data ref={ref} type={type} openid={openid} /> return <ww-open-data ref={ref} type={type} openid={openid} />
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment