Skip to content

Commit aa4059e

Browse files
committed
In code sandbox, show exercise titles in dropdown
1 parent 68137ed commit aa4059e

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

html/js/code.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,8 @@ addEventListener("load", function() {
7070
if (chapter.exercises.length) {
7171
per.appendChild(opt("box", "Select an exercise"));
7272
chapter.exercises.forEach(function(exercise) {
73-
per.appendChild(opt(chapter.number + "." + exercise.number));
73+
var num = chapter.number + "." + exercise.number;
74+
per.appendChild(opt(num, num + " " + exercise.name));
7475
});
7576
} else {
7677
per.appendChild(opt("box", "This chapter has no exercises"));

0 commit comments

Comments
 (0)