@0x/utils
0x TS utils
Last updated 20 days ago by dekz .
Apache-2.0 · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @0x/utils 
SYNC missed versions from official npm registry.

@0x/utils

Utils to be shared across 0x projects and packages

Installation

yarn add @0x/utils

If your project is in TypeScript, add the following to your tsconfig.json:

"compilerOptions": {
    "typeRoots": ["node_modules/@0x/typescript-typings/types", "node_modules/@types"],
}

Usage

import { addressUtils, bigNumberConfigs, classUtils, intervalUtils, promisify } from '@0x/utils';

Troubleshooting

If you are still seeing TS type errors complaining about missing DOM types such as Response:

error TS2304: Cannot find name 'Response'.

Then you need to explicitly add the dom lib to your compiler options in tsconfig.json. The dom library is included by default, but customizing the lib option can cause it to be dropped.

"compilerOptions": {
    "lib": [..., "dom"],

Contributing

We welcome improvements and fixes from the wider community! To report bugs within this package, please create an issue in this repository.

Please read our contribution guidelines before getting started.

Install dependencies

If you don't have yarn workspaces enabled (Yarn < v1.0) - enable them:

yarn config set workspaces-experimental true

Then install dependencies

yarn install

Build

To build this package and all other monorepo packages that it depends on, run the following from the monorepo root directory:

PKG=@0x/utils yarn build

Or continuously rebuild on change:

PKG=@0x/utils yarn watch

Clean

yarn clean

Lint

yarn lint

Current Tags

  • 5.5.0                                ...           latest (20 days ago)
  • 4.6.0-beta.3                                ...           protocolV3 (7 months ago)

39 Versions

  • 5.5.0                                ...           20 days ago
  • 5.4.1                                ...           5 months ago
  • 5.4.0                                ...           5 months ago
  • 5.3.0                                ...           5 months ago
  • 5.2.0                                ...           6 months ago
  • 5.1.2                                ...           6 months ago
  • 5.1.1                                ...           7 months ago
  • 5.1.0                                ...           7 months ago
  • 5.0.0                                ...           7 months ago
  • 4.6.0-beta.3                                ...           7 months ago
  • 4.6.0-beta.2                                ...           8 months ago
  • 4.6.0-beta.1                                ...           8 months ago
  • 4.6.0-beta.0                                ...           9 months ago
  • 4.5.2                                ...           10 months ago
  • 4.5.1                                ...           10 months ago
  • 4.5.0                                ...           a year ago
  • 4.4.2                                ...           a year ago
  • 4.4.1                                ...           a year ago
  • 4.4.0                                ...           a year ago
  • 4.3.3                                ...           a year ago
  • 4.3.1                                ...           a year ago
  • 4.3.0                                ...           a year ago
  • 4.2.3                                ...           a year ago
  • 4.2.2                                ...           a year ago
  • 4.2.1                                ...           a year ago
  • 4.2.0                                ...           a year ago
  • 4.1.0                                ...           a year ago
  • 4.0.3                                ...           a year ago
  • 4.0.2                                ...           a year ago
  • 4.0.1                                ...           a year ago
  • 3.0.1                                ...           a year ago
  • 3.0.0                                ...           2 years ago
  • 2.1.1                                ...           2 years ago
  • 2.0.8                                ...           2 years ago
  • 2.0.7                                ...           2 years ago
  • 2.0.6                                ...           2 years ago
  • 2.0.5                                ...           2 years ago
  • 2.0.4                                ...           2 years ago
  • 2.0.3                                ...           2 years ago
Downloads
Today 0
This Week 1
This Month 61
Last Day 1
Last Week 6
Last Month 134
Dependencies (13)
Dev Dependencies (14)
Dependents (92)

Copyright 2014 - 2016 © taobao.org |