Sort options array based on sorting configuration
Array of options to sort
Optional
Sort configuration: 'asc', 'desc', 'none', or custom comparator function
Sorted array (or original if 'none' or undefined)
Sort options array based on sorting configuration