import snakeCase from 'lodash.snakecase';
import courses from './../data/courses.json';

courses.forEach((course) => {
  course.id = snakeCase(course.title + course.author);
  if (typeof course.categories === 'string') { course.categories = course.categories.replace(/ *, */g, ',').split(','); }
  if (typeof course.flags === 'string') { course.flags = course.flags.split(','); }
});

export default function () {
  return courses;
}

@@ -378,16 +378,62 @@
  %7D%0A%7D);%0A%0A
+const reversed = courses.slice(0).reverse();%0A%0A
 export d
@@ -462,19 +462,20 @@
  return 
-courses
+reversed
 ;%0A%7D%0A

reversed the order of courses