// // YMAnchorCardSkillCollectionViewCell.m // YUMI // // Created by YUMI on 2022/8/2. // #import "XPAnchorCardSkillCollectionViewCell.h" ///Third #import @implementation XPAnchorCardSkillCollectionViewCell - (instancetype)initWithFrame:(CGRect)frame { if (self = [super initWithFrame:frame]) { [self initSubViews]; [self initSubViewConstraints]; } return self; } #pragma mark - Private Method - (void)initSubViews { [self.contentView addSubview:self.imageView]; } - (void)initSubViewConstraints { [self.imageView mas_makeConstraints:^(MASConstraintMaker *make) { make.leading.trailing.mas_equalTo(0); make.top.bottom.mas_equalTo(self.contentView); }]; } #pragma mark - Getters And Setters - (NetImageView *)imageView { if (!_imageView) { _imageView = [[NetImageView alloc] init]; _imageView.contentMode = UIViewContentModeScaleAspectFit; } return _imageView; } @end