import * as yup from 'yup'

const RSR = yup.object().shape({
  periodStart: yup.string(),
  periodEnd: yup.string(),
  targetValue: yup.string(),
  targetComment: yup.string()
})

const defs = {
  1: yup.array().of(RSR).min(1)
}

export default defs

@@ -183,40 +183,300 @@
 nst 
-defs = %7B%0A  1: yup.array().of(RSR
+IATI = RSR.clone().shape(%7B%0A  periodStart: yup.string().required(),%0A  periodEnd: yup.string().required(),%0A%7D)%0A%0Aconst DGIS = IATI.clone().shape(%7B%0A  targetValue: yup.string().required()%0A%7D)%0A%0Aconst defs = %7B%0A  1: yup.array().of(RSR).min(1),%0A  2: yup.array().of(IATI).min(1),%0A  3: yup.array().of(DGIS
 ).mi

Fix section 5 validations