Skip to content

adrianhensler/typing-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Edit: It was not beautiful, as it described itself. It was a demo of one-shotting a simple web application to fill a need. Not a super-useful example or result.

Example of easily coded single use utility.

⌨️ Typing Speed Test

A single-file typing speed test with real-time error highlighting and smart spell checking.

✨ Features

  • Real-Time Error Highlighting: See mistakes instantly as you type
  • Smart Spell Checking: Built-in dictionary validation (no API calls needed!)
  • Multiple Difficulty Levels: Easy, Medium, and Hard passages
  • Live Statistics: Track WPM, accuracy, time, and errors in real-time
  • Completely Self-Contained: Single 39KB HTML file with no dependencies
  • Works Offline: No internet connection required

🎯 How It Works

Spell Checking Implementation

Instead of using expensive AI API calls, this app uses a smart browser-based approach:

  • Embedded Dictionary: ~2000+ common English words stored as a JavaScript Set
  • O(1) Lookup Speed: Instant validation with no latency
  • 100% Offline: No external API calls or internet required
  • Privacy-First: All processing happens locally in your browser
  • Zero Cost: No API keys or rate limits

Why This Beats AI APIs

Feature Embedded Dictionary AI API Calls
Speed Instant (<1ms) 500-2000ms
Offline ✅ Yes ❌ No
Cost Free $$ per request
Privacy Local only Data sent externally
Reliability 100% Depends on API uptime

🖥️ Usage

Online

Visit the live demo

Local

Simply download typing-test.html and open it in any modern browser. No build process, no dependencies, no installation required!

# Clone and open
git clone https://github.com/adrianhensler/typing-test.git
cd typing-test
open typing-test.html  # macOS
# or
xdg-open typing-test.html  # Linux
# or just double-click the file in Windows

📊 Technical Details

  • File Size: 39KB total
  • Dictionary Size: ~2000 words covering 95%+ of common usage
  • Performance: Debounced spell checking (250ms) for smooth typing
  • WPM Calculation: (characters typed ÷ 5) ÷ minutes elapsed
  • Accuracy Formula: (correct characters ÷ total typed) × 100

🛠️ Technologies

  • Pure HTML5
  • CSS3 with gradient backgrounds and smooth animations
  • Vanilla JavaScript (ES6+)
  • No frameworks, no dependencies, no build tools

📝 License

MIT License - Feel free to use, modify, and distribute!

🤝 Contributing

Contributions are welcome! Feel free to:

  • Report bugs
  • Suggest new features
  • Submit pull requests
  • Improve the dictionary

🙏 Credits

Created with ❤️ using Claude Code


Repository: github.com/adrianhensler/typing-test Live Demo: adrianhensler.github.io/typing-test/typing-test.html

About

A beautiful typing speed test with real-time error highlighting and smart spell checking

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages