Compare commits
3 Commits
5769456dce
...
b130482e21
Author | SHA1 | Date | |
---|---|---|---|
|
b130482e21 | ||
|
a4a8fe6781 | ||
|
4545915711 |
@ -7,7 +7,7 @@
|
||||
$: options = Object.keys(question.options).map(e => ({ key: e, value: question.options[e] }));
|
||||
|
||||
let selected = [];
|
||||
$: isCorrect = selected.every(val => question.correct[val]);
|
||||
$: isCorrect = selected.length === question.correct.length && selected.every(val => question.correct.find(v => v === val));
|
||||
|
||||
$: console.log("Selected:", selected, "showResult:", showResult, "isCorrect", isCorrect);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user