get date from file name that has date and time in reverse order react js code example
Example 1: javascript order array by date
const sortedActivities = activities.sort((a, b) => b.date - a.date)
Example 2: array map order by timestamp reactjs
const sortedActivities = activities.slice().sort((a, b) => b.date - a.date)
Example 3: get date from file name that has date and time in reverse order
Get-ChildItem \\server\folder -Filter Examplefile*.txt |
Sort-Object { $_.BaseName -replace '.+(\d{2})(\d{2})(\d{2})', '$3$1$2' }