3.0.0 • Published 1 year ago
ajnavidya-file-upload-client v3.0.0
File Uploader Client
This Package demonstrates a file upload mechanism that breaks files into smaller chunks for more efficient transfer and utilizes a progress bar to track the upload process.
How to Use
npm i file-upload-client
Import Into File
import Uploader from "file-upload-client";
Example
function Upload() {
const [progress, setProgress] = useState(0);
const [fileURL, setFileURL] = useState("");
const getFileContext = (e) => {
const a = Uploader({
file: e,
setProgress: setProgress,
url: {
apiOrigin: "http://localhost:3002",
status: "/upload/status",
upload: "/upload/files",
complete: "/upload/complete",
},
setFileURL: setFileURL,
});
};
console.log("progress", progress);
console.log("fileURL", fileURL);
return <input type="file" onChange={getFileContext} />;
}
3.0.0
1 year ago
2.0.9
1 year ago
2.0.8
1 year ago
2.0.3
1 year ago
2.0.5
1 year ago
2.0.4
1 year ago
2.0.7
1 year ago
2.0.6
1 year ago
2.0.2
1 year ago
2.0.1
1 year ago
1.0.9
1 year ago
2.0.0
1 year ago
1.0.8
1 year ago
1.0.7
2 years ago
1.0.6
2 years ago
1.0.5
2 years ago
1.0.4
2 years ago
1.0.3
2 years ago
1.0.2
2 years ago
1.0.1
2 years ago
1.0.0
2 years ago
1.0.10
2 years ago