zoukankan      html  css  js  c++  java
  • React Native小知识点记录

    1>查看 RN 的所有历史版本:

    npm view react-native versions -json

    2>查看 RN 的当前版本:

    npm view react-native version -json

    3>平台判断执行方法:

    const Toolbar = Platform.select({
        android: () => renderToolbarAndroid(),
        ios: () => renderToolbarIOS()
      });

    4>分隔线的高度不能写死0.5,否则有些机型会有问题,如下所示:

    正确写法如下:

     container: {
            backgroundColor: 'white',
            borderTopWidth:StyleSheet.hairlineWidth,
            borderTopColor:'#ddd'
        },

    5>View固定屏幕底部:

    需要将view套在一个父view上,设置style如下:

    addArticelBottmViewStyle: {
            position: 'absolute',
             Space.kScreenWidth,
            height: 44,
            bottom: 0,
            right: 0 // 可不要
        }

    持续更新哟!!!

  • 相关阅读:
    59. Spiral Matrix II
    58. Length of Last Word
    57. Insert Interval
    56. Merge Intervals
    55. Jump Game
    54. Spiral Matrix
    53. Maximum Subarray
    52. N-Queens II
    51. N-Queens
    java封装学习
  • 原文地址:https://www.cnblogs.com/pengsi/p/7306963.html
Copyright © 2011-2022 走看看