Add i18n, tests, and update documentation
Introduces internationalization (i18n) support with English and Turkish, adds unit tests and test setup with Vitest and React Testing Library, and updates documentation including README and changelog. Removes legacy publishing and usage guides, refactors components to use translation system, and updates build and test scripts in package.json. Also adds new utility modules for HLS and CORS, and improves PlayerContext and SettingsMenu for language support.
This commit is contained in:
@@ -1,6 +1,38 @@
|
||||
# 🎬 Modern Video Player
|
||||
|
||||
A feature-rich, modern video player library built with React, TypeScript, and Vite. Designed for reusability across multiple projects with zero runtime dependencies.
|
||||
[](https://www.npmjs.com/package/@alper/video-player)
|
||||
[](https://bundlephobia.com/package/@alper/video-player)
|
||||
[](https://www.typescriptlang.org/)
|
||||
[](https://opensource.org/licenses/MIT)
|
||||
|
||||
**The smallest React video player with the most features.** Only **~15KB gzipped** with zero runtime dependencies!
|
||||
|
||||
A feature-rich, modern video player library built with React, TypeScript, and Vite. Designed for reusability across multiple projects.
|
||||
|
||||
## 🏆 Why Choose This Player?
|
||||
|
||||
| Feature | @alper/video-player | video.js | react-player | plyr |
|
||||
|---------|---------------------|----------|--------------|------|
|
||||
| **Bundle Size (gzipped)** | **15KB** ✅ | ~500KB ❌ | ~50KB ⚠️ | ~30KB ⚠️ |
|
||||
| **Runtime Dependencies** | **0** ✅ | Many ❌ | Few ⚠️ | Few ⚠️ |
|
||||
| **React Native** | **Yes** ✅ | Wrapper ⚠️ | **Yes** ✅ | Wrapper ⚠️ |
|
||||
| **TypeScript Native** | **Yes** ✅ | Types ⚠️ | Partial ⚠️ | Types ⚠️ |
|
||||
| **HLS Support** | **Yes** ✅ | Yes ✅ | Yes ✅ | No ❌ |
|
||||
| **Quality Switching** | **Yes** ✅ | Yes ✅ | Limited ⚠️ | No ❌ |
|
||||
| **Touch Gestures** | **15+** ✅ | Limited ⚠️ | No ❌ | Limited ⚠️ |
|
||||
| **Keyboard Shortcuts** | **15+** ✅ | ~8 ⚠️ | Basic ⚠️ | ~10 ⚠️ |
|
||||
| **i18n Support** | **Yes** ✅ | Yes ✅ | No ❌ | Yes ✅ |
|
||||
|
||||
### Key Advantages
|
||||
|
||||
- 📦 **97% smaller than video.js** - Only 15KB vs 500KB
|
||||
- ⚡ **Blazing fast** - Zero runtime dependencies means faster load times
|
||||
- 🎯 **React-first** - Built specifically for React, not a wrapper
|
||||
- 🔧 **Full TypeScript** - Complete type safety out of the box
|
||||
- 🎨 **Easy customization** - CSS variables for theming
|
||||
- 📱 **Mobile-ready** - Comprehensive touch gesture support
|
||||
- 🌍 **Internationalized** - Built-in i18n with English and Turkish
|
||||
- ♿ **Accessible** - ARIA labels and keyboard navigation
|
||||
|
||||
## ✨ Features
|
||||
|
||||
|
||||
Reference in New Issue
Block a user