<scroll-view
type="custom"
scroll-y="true"
show-scrollbar="{{true}}"
scroll-into-view="{{intoView}}"
class="scroll-view"
bindscrolltolower="bindscrolltolower"
style="margin-top: {{menuTop}}px;"
>
<grid-view type="masonry" cross-axis-count="{{crossAxisCount}}" cross-axis-gap="{{crossAxisGap}}" main-axis-gap="{{mainAxisGap}}">
<view wx:for="{{list}}" class="grid-box">
<image src="{{item.image_url}}" mode="widthFix" binderror="binderror"></image>
<view class="content-box">
<text>这里的风景好美~</text>
<view class="profile-text">
<view class="left">
<image class="icon" src="https://res.wx.qq.com/op_res/lS41C5Xp6y6mfUbelCW8PArEcMwWRuhSohPO46vAiELbhAf56_CwONEDgM2vIVxOlT5KDcSxCkV8xIJ6cg3x2Q"></image>
<text>binnie</text>
</view>
<view class="right">
<image class="icon-collection" src="https://res.wx.qq.com/community/dist/community/images/disagree_icon_fab2b7.svg"></image>
<text>666</text>
</view>
</view>
</view>
</view>
</grid-view>
</scroll-view>
代码片段如下:
scroll-view 要给高度,加个 height: 100vh 试试