A file splitting & merging solution.
For TypeScript / JavaScript environment:
# NPM
npm install @filego/ts
# Yarn
yarn add @filego/ts
# PNPM
pnpm add @filego/ts
For Node environment:
# NPM
npm install @filego/node
# Yarn
yarn add @filego/node
# PNPM
pnpm add @filego/node
Split file from a path to a directory directly with split
function in @filego/node
.
import { split } from "@filego/node";
await split({
inFile: "/path/to/file.txt",
outDir: "/path/to/dir",
chunkSize: 2 * 1024 * 1024,
});
For the usage of @filego/ts
, please refer to docs/ts.md.
For the usage of @filego/node
, please refer to docs/node.md.
Check out the Web and API examples.
Direcotry | Description | Link |
---|---|---|
Web | Web example in React | examples/web |
Node | Node example in Fastify | examples/node |
This project is MIT licensed, you can find the license file here.