I
let sectionView = GradeDetailsTitleView(frame: CGRect(x: 20, y: 0, width: backView1.frame.width-40, height: 50))
sectionView.configure(title: data.details[0].srction)
backView1.addSubview(sectionView)
NSLayoutConstraint.activate([sectionView.topAnchor.constraint(equalTo: backView1.topAnchor), sectionView.leftAnchor.constraint(equalTo: backView1.leftAnchor), sectionView.rightAnchor.constraint(equalTo: backView1.rightAnchor)])
let instructorView = GradeDetailsTitleView(frame: CGRect(x: 20, y: 0, width: backView1.frame.width-40, height: 50))
instructorView.configure(title: data.details[0].instructor)
backView1.addSubview(instructorView)
NSLayoutConstraint.activate([instructorView.topAnchor.constraint(equalTo: sectionView.bottomAnchor), instructorView.leftAnchor.constraint(equalTo: backView1.leftAnchor), instructorView.rightAnchor.constraint(equalTo: backView1.rightAnchor), instructorView.bottomAnchor.constraint(equalTo: backView1.bottomAnchor)])