iOS 13中setValue: forKey运行报错

iOS不允许valueForKey、setValue: forKey获取和设置私有属性,需要使用其它方式修改

_phoneTF.attributedPlaceholder = [[NSAttributedString alloc] initWithString:@"手机号" attributes:@{NSFontAttributeName:[UIFont boldSystemFontOfSize:Main_WidthPhx(30)],NSForegroundColorAttributeName:[UIColor whiteColor]}];

参考文章https://www.jianshu.com/p/973a00f57c6b

你可能感兴趣的:(iOS 13中setValue: forKey运行报错)