function validate(style) {
  let errors = []
  if (!style) {
    errors.push('no style')
    return errors
  }
  let { basemap, layers } = style
  if (!basemap || !basemap.style) {
    errors.push('require "basemap"')
  }
  if (!(layers instanceof Array)) {
    errors.push('require "layers"')
  }
  return errors
}

export default validate
