HippyRootView 自适应
ya0xu opened this issue · comments
Android 代码:
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fillViewport="true">
<LinearLayout
android:id="@+id/ll1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<HippyView
android:id="@+id/hv1"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
<HippyView
android:id="@+id/hv2"
android:layout_width="match_parent"
android:layout_height="wrap_content" />
</LinearLayout>
</androidx.core.widget.NestedScrollView>
hippy 版本:2.17.2
hippy 代码 vue-next
HippyView 继承自LinearLayoutCompat,在调用hippyRootView = hippyEngine.loadModule后,把hippyRootView添加HippView里面。 此时只显出来一个HippyView,占满了父容器的高度。没有实现自适应。
hv1、hv2设置固定高度则都可以显示 。
iOS通过sizeFlexiblity、rootViewDidChangeIntrinsicSize,使用同一套hippy代码,可以自适应,安卓怎样实现自适应呢?
Pay attention 🛎️ !!
There has been no activity on this issue for 2 months, so I will label it stalled.
It will be automatically closed in 60 days if no more activity. Feel free to leave a comment if you have any questions.