admin管理员组文章数量:1193346
i try to new dom components at Expo 52 in this article /guides/dom-components/
'use dom';
export default function DOMComponent({}: { dom: import('expo/dom').DOMProps }) {
return (
<div>
<h1>Hello, world!</h1>
</div>
);
}
import DOMComponent from './my-component';
export default function App() {
return (
<DOMComponent
dom={{
scrollEnabled: false,
}}
/>
);
}
but dom components props not work i mean the DOMComponent can scroll still
DomProps seesm like not work yet. By the way i created the project by this command
npx create-expo-app@latest
this project include SDK 52 and new arc true
i try to new dom components at Expo 52 in this article https://docs.expo.dev/guides/dom-components/
'use dom';
export default function DOMComponent({}: { dom: import('expo/dom').DOMProps }) {
return (
<div>
<h1>Hello, world!</h1>
</div>
);
}
import DOMComponent from './my-component';
export default function App() {
return (
<DOMComponent
dom={{
scrollEnabled: false,
}}
/>
);
}
but dom components props not work i mean the DOMComponent can scroll still
DomProps seesm like not work yet. By the way i created the project by this command
npx create-expo-app@latest
this project include SDK 52 and new arc true
Share Improve this question asked Jan 23 at 16:13 BerkooBerkoo 651 silver badge6 bronze badges1 Answer
Reset to default 0Did you try with any other props? I can't see anything wrong. I do it the same way, but with injectedJavaScript
and onMessage
, and it works fine. Note that scrollEnabled only works on iOS and macOS (in case you're testing on Android)
本文标签: react nativeExpo 52 Version Dom Components Props Not WorkStack Overflow
版权声明:本文标题:react native - Expo 52 Version Dom Components Props Not Work - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1738482748a2089241.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论