摘要:
1.把字体放在服务器上,因为字体图标比较大,小程序只支持2m 2.字体加载 3.检测是否加载成功(可能会存在https和http问题,防止跨域) 阅读全文
Android项目打包遇com.android.builder.internal.aapt.v2.Aapt2Exception: AAPT2 error: check logs for details
摘要:
查了网上很多处理都是在项目的gradle.properties中添加下面的配置,再编译就通过了:android.enableAapt2=false 阅读全文
摘要:
let arr =[1,2,3,4] console.log(arr) //[1,2,3,4] let arr2 = arr; console.log(arr2) //[4,3,2,1] console.log(arr) //[4,3,2,1] reverse():该方法会改变原来的数组,而不会创建 阅读全文
摘要:
import { withNavigationFocus } from 'react-navigation'; class Warngreete extends React.Component { constructor(props) { super(props); } componentDidMo 阅读全文
摘要:
父组件: 引入子组件:import CheckBox from '../checkbox'; 父子之间交互通信,接受子组件的值 fn(val){this.setState({roleType:val});} //调用通信 <CheckBox data={this.state.roleType} is 阅读全文
摘要:
Properties 阅读全文
摘要:
navigationOptions: ({navigation}) => ({ headerTitle:'评估记录', headerBackTitle:null, headerLeft:null, headerStyle: { backgroundColor: '#000', color:'#fff 阅读全文
摘要:
在最外部声明: let that; 在class内部: constructor(props){ super(props); that = this; } 在const * = StackNavigation({})中: static navigationOptions = ({ navigation 阅读全文
摘要:
使用以下代码获取navigation static navigationOptions = ({ navigation, navigationOptions }) => { const { params } = navigation.state; return { tabBarVisible: tr 阅读全文
摘要:
数字变字符串:str+'' 字符串变数字:str-0 阅读全文