code: func WriteJSONFile(name, prefix, indent string, data interface{}) error {
  	file, err := os.Create(name)
  	if err != nil {
  		return err
  	}
  	defer file.Close()
  
  	enc := json.NewEncoder(file)
  	enc.SetIndent(prefix, indent)
  	return enc.Encode(data)
  }
docs: // WriteJSONFile converts a given data instance to JSON and writes it to file.