<view class='big'> <image class='img' src='../image/tupian.png'></image> <text>文字</text> </view>
.big{ display: flex; //彈性布局 flex-direction: row; //靈活的項目將水平顯示,正如一個行一樣。 align-items: center; //元素位於容器的垂直中間 justify-content: center; //項目位於容器的水平中心。 }
<view class='big'> <image class='img' src='../image/tupian.png'></image> <text>文字</text> </view>
.big{ display: flex; //彈性布局 flex-direction: row; //靈活的項目將水平顯示,正如一個行一樣。 align-items: center; //元素位於容器的垂直中間 justify-content: center; //項目位於容器的水平中心。 }
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。