如何解决如何在React Native中创建Firebase自定义动态链接
**
// using I18nManager you can get initial direction of device or you can use async storage or both of them as combined. i really dont care now...
const LanguageDirectionContext = createContext({
direction: 'ltr'
})
const LanguageDirectionProvider = ({ children }) => {
const [direction,setDirection] = useState('ltr')
const toggleDirection = () => {
setDirection(direction === 'ltr' ? 'rtl' : 'ltr')
}
useEffect(() => {
// use I18nManager to force direction and use asyncstorage to save the current direction to device.
},[direction])
return (
<LanguageDirectionContext.Provider value={{
direction,toggleDirection
}}>
{children}
</LanguageDirectionContext.Provider>
)
}
**
我尝试了上面的代码在react native中创建动态链接,并且下面的链接是从上面的代码创建的 https://narola.page.link/post/12345?link=https%3A%2F%2Finvertase.io
但是当尝试从上面的链接打开应用程序时,它说无效的动态链接。 注意:必须使用参数创建动态链接。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。