Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface AddOptions

Hierarchy

Index

Properties

blockWriteConcurrency?: number

How many blocks from a file to write concurrently

chunker?: string

Chunking algorithm used to build ipfs DAGs. (defaults to 'size-262144')

cidVersion?: CIDVersion

The CID version to use when storing the data

hashAlg?: string

Multihash hashing algorithm to use. (Defaults to 'sha2-256')

onlyHash?: boolean

If true, will not add blocks to the blockstore. (Defaults to false)

pin?: boolean

Pin this object when adding. (Defaults to true)

preload?: boolean

Whether to preload all blocks created during this operation

progress?: AddProgressFn

A function that will be called with the number of bytes added as a file is added to ipfs and the path of the file being added.

Note It will not be called for directory entries.

rawLeaves?: boolean

If true, DAG leaves will contain raw file data and not be wrapped in a protobuf. (Defaults to false)

signal?: AbortSignal

Can be provided to a function that starts a long running task, which will be aborted when signal is triggered.

timeout?: number

Can be provided to a function that starts a long running task, which will be aborted after provided timeout (in ms).

trickle?: boolean

If true will use the trickle DAG format for DAG generation. (Defaults to false).

wrapWithDirectory?: boolean

Adds a wrapping node around the content. (Defaults to false)

Generated using TypeDoc