{"id":51388353,"url":"https://github.com/ewels/starlight-quiz","last_synced_at":"2026-07-03T21:35:30.622Z","repository":{"id":367743147,"uuid":"1282087448","full_name":"ewels/starlight-quiz","owner":"ewels","description":null,"archived":false,"fork":false,"pushed_at":"2026-06-27T13:07:33.000Z","size":153,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-06-27T13:08:27.264Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ewels.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-06-27T09:58:10.000Z","updated_at":"2026-06-27T09:58:15.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ewels/starlight-quiz","commit_stats":null,"previous_names":["ewels/starlight-quiz"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/ewels/starlight-quiz","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewels%2Fstarlight-quiz","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewels%2Fstarlight-quiz/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewels%2Fstarlight-quiz/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewels%2Fstarlight-quiz/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ewels","download_url":"https://codeload.github.com/ewels/starlight-quiz/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ewels%2Fstarlight-quiz/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35102741,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-03T02:00:05.635Z","response_time":110,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-07-03T21:35:30.024Z","updated_at":"2026-07-03T21:35:30.616Z","avatar_url":"https://github.com/ewels.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n\u003cpicture\u003e\n  \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/ewels/starlight-quiz/main/docs/src/assets/logo/starlight-quiz-horizontal-dark.svg\" /\u003e\n  \u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/ewels/starlight-quiz/main/docs/src/assets/logo/starlight-quiz-horizontal-light.svg\" /\u003e\n  \u003cimg alt=\"starlight-quiz\" src=\"https://raw.githubusercontent.com/ewels/starlight-quiz/main/docs/src/assets/logo/starlight-quiz-horizontal-light.svg\" width=\"640\" /\u003e\n\u003c/picture\u003e\n\n[![npm version](https://img.shields.io/npm/v/starlight-quiz.svg)](https://www.npmjs.com/package/starlight-quiz)\n[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/ewels/starlight-quiz/blob/main/LICENSE)\n[![Documentation](https://img.shields.io/badge/docs-ewels.github.io-7c3aed.svg)](https://ewels.github.io/starlight-quiz)\n\n\u003c/div\u003e\n\nA plugin to create interactive quizzes directly in your [Starlight](https://starlight.astro.build/) or plain [Astro](https://astro.build/) markdown documentation. Perfect for\neducational content, tutorials, and documentation that requires reader engagement.\n\n## Features\n\n- ✨ **Simple markdown syntax** - write quizzes with GitHub-flavoured task lists, no new syntax to learn\n- 🎯 **Multiple quiz types** - single choice (radio), multiple choice (checkboxes), and fill-in-the-blank\n- ⚡ **Instant feedback** - per-answer feedback and visual correct/incorrect indicators\n- 📝 **Rich explanations** - reveal a markdown content section after answering, with code blocks, tables and images\n- 📊 **Progress \u0026amp; results** - an aggregate results panel with score tiers and confetti :tada:\n- 💾 **Results saved** - answers persist to the browser's local storage, surviving reloads and rebuilds\n- 🔀 **Author controls** - shuffle answers, auto-number questions, and set site-wide behaviour defaults\n- 🌐 **Internationalisation** - 13 languages out of the box (shared with mkdocs-quiz), with label props otherwise\n- 🧩 **Works anywhere** - a zero-config Starlight plugin or standalone in any Astro project, safe under view transitions\n- ♿ **Accessible** - real fieldsets, `aria-live` feedback, focus management and keyboard-safe auto-submit\n- 📤 **LMS export** - emit a quiz manifest and export to QTI 1.2/2.1 for Canvas, Moodle and Blackboard\n- 🖥️ **Terminal runner** - take quizzes in your terminal, from a local build or a deployed site\n\n```mdx\nimport { Quiz } from 'starlight-quiz/components';\n\n\u003cQuiz title=\"Static site generators\"\u003e\nWhich of these are static site generators?\n\n- [x] Astro\n- [ ] Django\n- [x] Eleventy\n\nAstro and Eleventy build static sites, while Django is a web framework.\n\n\u003c/Quiz\u003e\n```\n\n## Installation\n\n```sh\nnpm install starlight-quiz\n```\n\n## Usage\n\n### As a Starlight plugin (zero config)\n\nAdd the plugin to your Starlight configuration — it wires up the styles and translations for you:\n\n```js\n// astro.config.mjs\nimport starlight from '@astrojs/starlight';\nimport starlightQuiz from 'starlight-quiz';\nimport { defineConfig } from 'astro/config';\n\nexport default defineConfig({\n  integrations: [\n    starlight({\n      title: 'My docs',\n      plugins: [starlightQuiz()],\n    }),\n  ],\n});\n```\n\nThen import the components in any `.mdx` page and author your quiz with markdown:\n\n```mdx\nimport { Quiz, QuizResults } from 'starlight-quiz/components';\n\n\u003cQuiz title=\"Primary colours\"\u003e\nWhich of these are primary colours?\n\n- [x] Red\n- [ ] Green\n  \u003e Green is a secondary colour.\n- [x] Blue\n\nPrimary colours cannot be made by mixing other colours.\n\n\u003c/Quiz\u003e\n\n\u003cQuiz title=\"Cell biology\"\u003e\nThe powerhouse of the cell is the [[mitochondria]].\n\u003c/Quiz\u003e\n\n\u003cQuizResults confetti /\u003e\n```\n\n### Standalone in any Astro project\n\nThe components have no hard dependency on Starlight. Import them the same way and the stylesheet yourself, passing label\nprops for any text you want to translate:\n\n```astro\n---\nimport { Quiz } from 'starlight-quiz/components';\nimport 'starlight-quiz/styles';\n---\n\n\u003cQuiz title=\"Quick check\" submitLabel=\"Check answer\"\u003e\nIs the sky blue?\n\n- [x] Yes\n- [ ] No\n\u003c/Quiz\u003e\n```\n\n## Documentation\n\nFull guides, the authoring reference and a live demo are on the **[documentation site](https://ewels.github.io/starlight-quiz)**.\n\n## License\n\nThis project is licensed under the [Apache License 2.0](https://github.com/ewels/starlight-quiz/blob/main/LICENSE).\n\n## Credits\n\n- Created by [Phil Ewels](https://github.com/ewels)\n- Ported from [mkdocs-quiz](https://github.com/ewels/mkdocs-quiz), originally by [Sebastian Jörz](https://github.com/skyface753) before being rewritten by [Phil Ewels](https://github.com/ewels).\n\n\u003e [!TIP]\n\u003e **Writing docs with [MkDocs](https://www.mkdocs.org/) instead?**\u003cbr\u003e\n\u003e Try [**mkdocs-quiz**](https://ewels.github.io/mkdocs-quiz/), which brings the same markdown quiz syntax to MkDocs and [Material for MkDocs](https://squidfunk.github.io/mkdocs-material/).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fewels%2Fstarlight-quiz","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fewels%2Fstarlight-quiz","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fewels%2Fstarlight-quiz/lists"}