fileTypes property
Giving user option to choose which file type to write.
And also this fileTypes will be used as a parameter to displayed these file types only in file explorer.
List<String> fileTypes = ['txt','rtf','html'];
Implementation
final List<String>? fileTypes;