Forum Discussion

DanielBenton's avatar
DanielBenton
Community Member
2 days ago

Boost Your Storyline Game with JavaScript!

PREVIEW COURSE.

For as long as I can remember, corporate e-learning has relied heavily on multiple-choice questions to assess learners. It’s never felt like the best approach to me. Even before I stepped into L&D, I found it often tested someone’s ability to pick the best option, rather than truly assessing whether they knew the answer. That’s why I focus on using open-text questions whenever possible.

For this quiz, I used JavaScript to:

  • Create a typewriter effect for text displays.
  • Build a huge question bank with over 100 questions, with typo-tolerant marking using the Levenshtein algorithm. This allows answers with small spelling errors (like “Lichenstein” instead of “Liechtenstein”) to be marked correct.
  • Dynamically load and shuffle questions, ensuring no repeats within the same session.
  • Provide real-time scoring adjustments with immediate feedback.

Recently, I’ve been experimenting with OpenAI’s API to evaluate open-text answers and provide personalised feedback. While it’s incredible what AI can achieve, it’s not always practical or cost-effective. That’s where JavaScript comes in—it allows for powerful customisations directly within the project file, offering a practical alternative, or compliment to AI.

ChatGPT helped me convert these ideas into working code, and I’m happy to share it with you to adapt and enhance for your own projects. Let me know how you’d use these ideas in your e-learning modules—I’d love to see what you create! 🚀

I've shared the project master file, so feel free to explore, adapt, or reuse it in your own projects.

No RepliesBe the first to reply