Module @zk-kit/utils

Utils

Essential zero-knowledge utility library for JavaScript developers.

NPM license NPM version Downloads npm bundle size (scoped) Linter eslint Code style prettier

🗣️ Chat & Support   |   📘 Docs

[!WARNING]
This library has not been audited.

🛠 Install

npm or yarn

Install the @zk-kit/utils package and its peer dependencies with npm:

npm i @zk-kit/utils

or yarn:

yarn add @zk-kit/utils

CDN

You can also load it using a script tag using unpkg:

<script src="https://unpkg.com/@zk-kit/utils"></script>

or JSDelivr:

<script src="https://cdn.jsdelivr.net/npm/@zk-kit/utils"></script>

📜 Usage

// You can import modules from the main bundle.
import { errorHandlers, typeChecks } from "@zk-kit/utils"

// Or by using conditional exports.
import { requireNumber } from "@zk-kit/utils/error-handlers"
import { isNumber } from "@zk-kit/utils/type-checks"

For more information on the functions provided by @zk-kit/utils, please refer to the documentation.

References

Re-exports SupportedType
Re-exports beBigIntToBuffer
Re-exports beBufferToBigInt
Re-exports bigIntToBuffer
Re-exports bigIntToHexadecimal
Re-exports bigNumberishToBigInt
Re-exports bigNumberishToBuffer
Re-exports bufferToBigInt
Re-exports bufferToHexadecimal
Re-exports hexadecimalToBigInt
Re-exports hexadecimalToBuffer
Re-exports isArray
Re-exports isBigInt
Re-exports isBigNumber
Re-exports isBigNumberish
Re-exports isBuffer
Re-exports isDefined
Re-exports isFunction
Re-exports isHexadecimal
Re-exports isNumber
Re-exports isObject
Re-exports isString
Re-exports isStringifiedBigInt
Re-exports isSupportedType
Re-exports isType
Re-exports isUint8Array
Re-exports leBigIntToBuffer
Re-exports leBufferToBigInt
Re-exports packGroth16Proof
Re-exports requireArray
Re-exports requireBigInt
Re-exports requireBigNumber
Re-exports requireBigNumberish
Re-exports requireBuffer
Re-exports requireDefined
Re-exports requireFunction
Re-exports requireHexadecimal
Re-exports requireNumber
Re-exports requireObject
Re-exports requireString
Re-exports requireStringifiedBigInt
Re-exports requireTypes
Re-exports requireUint8Array
Re-exports unpackGroth16Proof

Generated using TypeDoc