Based exclusively on the official Discover Canada / Découvrir le Canada guide from Immigration, Refugees and Citizenship Canada.
- 450+ questions drawn directly from the official study guide
- Same format as the real test — 20 random questions, 45-minute timer, 75% to pass
- Immediate feedback with source reference (section + PDF page link)
- Fully bilingual — English and French, switchable mid-session
- No account needed — statistics stored locally in your browser / on your device
- Dark mode — web toggle or system preference on mobile
- Mobile app — iOS & Android via Expo (React Native)
- Node.js 18+
- npm 7+ (workspaces support)
citizenship/
├── apps/
│ ├── web/ # Next.js 15 web app
│ └── mobile/ # Expo (React Native) iOS/Android app
├── packages/
│ └── core/ # Shared logic: questions, quiz, stats, translations
└── package.json # Workspace root
git clone https://github.com/Gcx44/leafready.git
cd leafready
npm install # installs all workspaces at onceNote: The official study guide PDFs are not included in the repository. Place them manually in
apps/web/public/documents/if you want source links to work locally:
apps/web/public/documents/discover.pdfapps/web/public/documents/decouvrir.pdfYou can download them from canada.ca.
All commands run from the monorepo root:
npm run dev:web # Dev server → http://localhost:3000
npm run build:web # Production build
npm run lint:web # ESLintTo run on a simulator you need either:
- iOS simulator — install Xcode from the Mac App Store
- Android emulator — install Android Studio and create a virtual device (AVD)
The quickest option without installing any simulator: install Expo Go on your physical iPhone or Android device.
npm run dev:mobileThis runs expo start inside apps/mobile/. An interactive menu appears in the terminal:
| Key | Action |
|---|---|
i |
Open in iOS Simulator (requires Xcode) |
a |
Open in Android Emulator (requires Android Studio) |
s |
Switch to Expo Go mode, then scan the QR code with your phone |
Physical device: make sure your phone and Mac are on the same Wi-Fi network, then scan the QR code with:
- iPhone → the native Camera app
- Android → the Expo Go app
Contributions are welcome. The most impactful way to help is to add or improve questions.
All questions live in packages/core/src/questions.json. Each entry must follow this schema:
{
"id": 386,
"category": "government",
"en": {
"question": "What is the name of Canada's national anthem?",
"choices": [
"O Canada",
"God Save the King",
"The Maple Leaf Forever",
"True North Strong and Free"
],
"answer": 0
},
"fr": {
"question": "Quel est le nom de l'hymne national du Canada ?",
"choices": [
"Ô Canada",
"God Save the King",
"The Maple Leaf Forever",
"Vrai Nord fort et libre"
],
"answer": 0
},
"source": {
"page_en": 45,
"page_fr": 47,
"section_en": "Symbols of Canada",
"section_fr": "Symboles du Canada"
}
}Rules:
idmust be unique and sequential (no gaps)- Both
enandfrversions are required answeris the index (0–3) of the correct choice inchoices- Content must come exclusively from the official Discover Canada guide
source.page_*can be approximate
Valid categories:
| Key | Label |
|---|---|
rights_responsibilities |
Rights & Responsibilities |
who_we_are |
Who We Are |
history_aboriginal |
Aboriginal History |
history_european |
European History |
modern_canada |
Modern Canada |
government |
Government |
federal_elections |
Federal Elections |
justice_system |
Justice System |
symbols |
Canadian Symbols |
economy |
Economy |
regions |
Canada's Regions |
- Bug fixes
- UI/UX improvements
- Accessibility improvements
- Translation corrections
Please open an issue before starting significant work.
| Layer | Web | Mobile |
|---|---|---|
| Framework | Next.js 15 (App Router) | Expo + Expo Router |
| Styling | Tailwind CSS v3 | NativeWind v4 |
| i18n | next-intl | i18n-js + expo-localization |
| Data | @leafready/core (shared package) |
@leafready/core (shared package) |
| Stats | localStorage |
AsyncStorage |
| Hosting | Netlify | App Store / Play Store (coming soon) |
No backend. No database. No cookies. No account required.
The web app is configured for Netlify:
# apps/web/netlify.toml
[build]
base = "apps/web"
command = "cd ../.. && npm install && npm run build:web"
publish = ".next"Language-based redirects are configured automatically (EN/FR based on browser language).
This is an unofficial practice tool. It is not affiliated with, endorsed by, or connected to the Government of Canada or Immigration, Refugees and Citizenship Canada (IRCC).
The official study guide remains the only authoritative source for the citizenship test.