- ✅ Monorepo scaffolding with pnpm workspaces
- ✅ TypeScript configuration with strict mode
- ✅ ESLint and Prettier setup
- ✅ Vitest testing framework
- ✅ Docker Compose with MinIO
- ✅ GitHub Actions CI workflow
- ✅ Comprehensive .gitignore
- ✅ TypeScript types and interfaces
- ✅ Type-safe event emitter
- ✅ File validation (type, size, extension, image dimensions)
- ✅ Filename utilities (scrubbing, unique prefixes, content-disposition)
- ✅ Content-type detection
- ✅ Unique ID generation
- ✅ Exponential backoff retry strategy with jitter
- ✅ Mock provider for testing
- ✅ S3 provider for real backend integration
- ✅ Upload manager with task orchestration
- ✅ Concurrency control
- ✅ Abort/pause/resume functionality
- ✅ Progress tracking with XHR
- ✅ createUploader factory function
- ✅ Comprehensive test coverage
- ✅ useUploader hook for multi-file uploads
- ✅ useUpload hook for single-file uploads
- ✅ React state management with events
- ✅ Aggregate progress calculation
- ✅ Auto-cleanup on unmount
- ✅ Full TypeScript support
- ✅ React basic example with Vite
- ✅ Beautiful UI with gradient design
- ✅ Mock provider demo
- ✅ Progress tracking
- ✅ Error handling
- ✅ Root README with quick start
- ✅ CONTRIBUTING guide
- ✅ Package READMEs
- ✅ Example documentation
- ✅ MIT License
@awesome-s3-uploader/
├── packages/
│ ├── core/ # @awesome-s3-uploader/core v0.1.0
│ │ ├── src/
│ │ │ ├── types.ts
│ │ │ ├── uploader.ts
│ │ │ ├── upload-manager.ts
│ │ │ ├── upload-task.ts
│ │ │ ├── providers/
│ │ │ │ ├── mock-provider.ts
│ │ │ │ └── s3-provider.ts
│ │ │ ├── validators/
│ │ │ │ └── file-validator.ts
│ │ │ ├── retry/
│ │ │ │ └── exponential-backoff.ts
│ │ │ └── utils/
│ │ │ ├── event-emitter.ts
│ │ │ ├── filename.ts
│ │ │ ├── content-type.ts
│ │ │ ├── unique-id.ts
│ │ │ └── abort-controller.ts
│ │ └── tests/ # Comprehensive test suite
│ └── react/ # @awesome-s3-uploader/react v0.1.0
│ └── src/
│ ├── hooks/
│ │ ├── use-uploader.ts
│ │ └── use-upload.ts
│ └── index.ts
└── examples/
└── react/ # Working demo app
pnpm installpnpm buildpnpm testcd examples/react
pnpm install
pnpm dev- Implement multipart upload execution (architecture ready)
- Add React components (DropZone, FileInput, ProgressBar)
- Create additional examples (dropzone, Next.js, vanilla JS)
- Set up Docusaurus documentation site
- Add server examples (Express, Lambda, Flask)
- Implement pause/resume for multipart uploads
- Add integration tests with MinIO
- Set up changesets for versioning
- Publish to npm
import { createUploader } from '@awesome-s3-uploader/core';
const uploader = createUploader({ provider: 'mock' });
uploader.addFiles(files);import { useUpload } from '@awesome-s3-uploader/react';
const { upload, status, progress } = useUpload({ provider: 'mock' });const uploader = createUploader({
provider: 'mock',
validation: {
maxFileSize: 50 * 1024 * 1024,
allowedTypes: ['image/*'],
image: { maxWidth: 4000, maxHeight: 4000 }
}
});import { createS3Provider } from '@awesome-s3-uploader/core';
const uploader = createUploader({
provider: createS3Provider({ signingUrl: '/api/s3/sign' })
});- Total Files: 50+
- Lines of Code: ~3,500+
- Test Files: 8
- Packages: 2
- Examples: 1
- Commits: 12
- Framework Agnostic - Core works everywhere
- Zero Dependencies - Core has no runtime deps
- TypeScript First - Full type safety
- Mock Provider - Test without backend
- Progress Tracking - Real-time upload progress
- Retry Logic - Exponential backoff with jitter
- File Validation - Comprehensive validation rules
- Concurrent Uploads - Configurable concurrency
- Abort/Pause/Resume - Full upload control
- Event-Driven - Subscribe to all lifecycle events
- Provider Pattern - Pluggable backends (S3, mock, future: GCS, R2)
- Immutable State - Task updates are immutable
- Event Emitter - Type-safe event system
- Retry Strategy - Configurable with custom predicates
- Validation Pipeline - Extensible validation system
- XHR for Progress - XMLHttpRequest for upload progress
- AbortController - Modern cancellation API
04b0fe7 feat(examples): add React basic example application
6c15a75 chore: add infrastructure and development setup
41ff3dc feat(react): add React hooks for file uploads
d8b05c6 docs: add comprehensive README and gitignore
7597820 feat(core): add S3 provider and complete core package
04b891f feat(core): add upload manager and task handling
05470a6 feat(core): add mock provider for testing and demos
2a889a5 feat(core): add exponential backoff retry strategy
50bf562 feat(core): add file validation with comprehensive rules
6a84e65 feat(core): add utility functions for file handling
15d40af feat(core): add TypeScript types and event emitter
49fb812 chore: scaffold monorepo structure with pnpm workspace
- ✅ TypeScript strict mode enabled
- ✅ Comprehensive test coverage
- ✅ Zero runtime dependencies in core
- ✅ Clean commit history
- ✅ Well-documented code
- ✅ Follows best practices
- ✅ Production-ready architecture
See examples/react for a complete working demo with:
- File selection
- Upload progress
- Success/error states
- Beautiful UI
- Mock provider (works immediately)