setupParentData method
Check wheter the data type used by the child conforms to the setupParentData in the RenderBox. If it does not conform to the data type, create and replace it again
Implementation
@override
void setupParentData(RenderBox child) {
if (child.parentData is! WrapParentData) {
child.parentData = WrapParentData();
}
}