如果是IOS Native
如果你尝试,并设置缩放比例为零,你会得到这个消息:<Error>: CGAffineTransformInvert: singular matrix.
[UIView animateWithDuration:0.5 animations:^{
CGAffineTransform newTransform = CGAffineTransformScale(myView, 0.0, 0.0);
[myView setTransform:newTransform];
} completion:^(BOOL finished) {
}];
改为:CGAffineTransform newTransform = CGAffineTransformScale(s.transform, 0.0001f, 0.00001f);
但是RN里面的webview 并没有这些东西
根据 http://stackoverflow.com/questions/17145114/error-cgaffinetransforminvert-singular-matrix
这里面的问题讨论,就是因为webview 的 frame 问题导致,
需要设置webview 的是style,而不是在父组件中设置