It is sometime desired to use a single struct to generate multiple CSVs, with a subset of the fields in each run
Currently, the only way to ignore fields is using tag csv:"-" which is fixed at compile time which makes it impossible to decide which fields should be encoded at runtime
I'm proposing a simple solution to add an optional FieldFilter func that accepts csv field name and return true to include the field or not, this would be a property of the Encoder similar to Tag and Autoheader
It is sometime desired to use a single struct to generate multiple CSVs, with a subset of the fields in each run Currently, the only way to ignore fields is using tag csv:"-" which is fixed at compile time which makes it impossible to decide which fields should be encoded at runtime I'm proposing a simple solution to add an optional FieldFilter func that accepts csv field name and return true to include the field or not, this would be a property of the Encoder similar to Tag and Autoheader