A Blazor library for creating read-only file streams from file inputs and drag-and-drop targets with fine-grained control over memory usage.
BlazorFileReader is a library for Blazor applications that provides read-only file streams from HTML file input elements and drag-and-drop targets. It solves the problem of handling file uploads in Blazor by offering a stream-based API that allows developers to read files in chunks, control memory usage, and support large files efficiently.
Blazor developers building web applications that require file upload functionality, especially those needing fine-grained control over file reading, memory management, or support for large files.
Developers choose BlazorFileReader over the built-in InputFile component for its advanced features like buffer size control, progress reporting, cancellation support, and flexibility in handling large files with optimized memory usage.
Library for creating read-only file streams from file input elements or drop targets in Blazor.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Exposes files as read-only streams for asynchronous chunked reading, optimizing memory usage for large files, as emphasized in the Key Features and demo projects.
Supports flexible input methods with drag-and-drop targets and copy/paste integration from the clipboard, providing user-friendly alternatives to standard file inputs.
Allows cancellation via CancellationToken in most methods and includes native progress reporting, essential for managing long uploads with user feedback.
Enables developers to specify buffer sizes for reading files, balancing performance and memory consumption, as detailed in the documentation and setup options.
Requires different IoC configurations for client-side vs. server-side Blazor and depends on specific SDK versions, leading to potential compatibility issues and frequent updates.
Has documented gotchas like problems with StreamReader in Release mode due to compiler optimizations, necessitating workarounds or specific Blazor versions.
Using methods like IFileReference.CreateMemoryStreamAsync() without arguments can block the UI during transfer for large files, as warned in the Gotcha's section.