Function
Orders every catalog course for Available courses' lobby: the learner's courses first, then every course they have not joined, in catalog order.
The learner's courses, the one to lead with first
Every catalog course's view
One entry per catalog course
enrolled is taken in the order given — useCourseShelf already puts the course watched most recently first — so the lobby and My learning agree on which course leads.
enrolled
useCourseShelf
const lobby = courseLobby([shelf.featured, ...shelf.otherEnrolled], courses); Copy
const lobby = courseLobby([shelf.featured, ...shelf.otherEnrolled], courses);
Orders every catalog course for Available courses' lobby: the learner's courses first, then every course they have not joined, in catalog order.