Catalog npm
Back to packageRELEASE DETAILS

1.0.9

npm

@0xproject/utils

0x TS utils

Published21 Sept 2018
Direct dependencies24
Transitive dependenciesNot calculated

README

Current package documentation

@0xproject/utils

Utils to be shared across 0x projects and packages

Installation

yarn add @0xproject/utils

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

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

Usage

import { addressUtils, bigNumberConfigs, classUtils, intervalUtils, promisify } from '@0xproject/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=@0xproject/utils yarn build

Or continuously rebuild on change:

PKG=@0xproject/utils yarn watch

Clean

yarn clean

Lint

yarn lint

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 24

Native requirements
24 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
@0xproject/types
Environment
{
  "local_name": "@0xproject/types",
  "alias": false,
  "peer_metadata": null
}
^1.0.2runtime
@0xproject/typescript-typings
Environment
{
  "local_name": "@0xproject/typescript-typings",
  "alias": false,
  "peer_metadata": null
}
^2.0.1runtime
@types/node
Environment
{
  "local_name": "@types/node",
  "alias": false,
  "peer_metadata": null
}
*runtime
abortcontroller-polyfill
Environment
{
  "local_name": "abortcontroller-polyfill",
  "alias": false,
  "peer_metadata": null
}
^1.1.9runtime
bignumber.js
Environment
{
  "local_name": "bignumber.js",
  "alias": false,
  "peer_metadata": null
}
~4.1.0runtime
detect-node
Environment
{
  "local_name": "detect-node",
  "alias": false,
  "peer_metadata": null
}
2.0.3runtime
ethereum-types
Environment
{
  "local_name": "ethereum-types",
  "alias": false,
  "peer_metadata": null
}
^1.0.7runtime
ethereumjs-util
Environment
{
  "local_name": "ethereumjs-util",
  "alias": false,
  "peer_metadata": null
}
^5.1.1runtime
ethers
Environment
{
  "local_name": "ethers",
  "alias": false,
  "peer_metadata": null
}
3.0.22runtime
isomorphic-fetch
Environment
{
  "local_name": "isomorphic-fetch",
  "alias": false,
  "peer_metadata": null
}
^2.2.1runtime
js-sha3
Environment
{
  "local_name": "js-sha3",
  "alias": false,
  "peer_metadata": null
}
^0.7.0runtime
lodash
Environment
{
  "local_name": "lodash",
  "alias": false,
  "peer_metadata": null
}
^4.17.5runtime
@0xproject/tslint-config
Environment
{
  "local_name": "@0xproject/tslint-config",
  "alias": false,
  "peer_metadata": null
}
^1.0.7development
@types/detect-node
Environment
{
  "local_name": "@types/detect-node",
  "alias": false,
  "peer_metadata": null
}
2.0.0development
@types/lodash
Environment
{
  "local_name": "@types/lodash",
  "alias": false,
  "peer_metadata": null
}
4.14.104development
@types/mocha
Environment
{
  "local_name": "@types/mocha",
  "alias": false,
  "peer_metadata": null
}
^2.2.42development
chai
Environment
{
  "local_name": "chai",
  "alias": false,
  "peer_metadata": null
}
^4.0.1development
copyfiles
Environment
{
  "local_name": "copyfiles",
  "alias": false,
  "peer_metadata": null
}
^2.0.0development
make-promises-safe
Environment
{
  "local_name": "make-promises-safe",
  "alias": false,
  "peer_metadata": null
}
^1.1.0development
mocha
Environment
{
  "local_name": "mocha",
  "alias": false,
  "peer_metadata": null
}
^4.1.0development
npm-run-all
Environment
{
  "local_name": "npm-run-all",
  "alias": false,
  "peer_metadata": null
}
^4.1.2development
shx
Environment
{
  "local_name": "shx",
  "alias": false,
  "peer_metadata": null
}
^0.2.2development
tslint
Environment
{
  "local_name": "tslint",
  "alias": false,
  "peer_metadata": null
}
5.11.0development
typescript
Environment
{
  "local_name": "typescript",
  "alias": false,
  "peer_metadata": null
}
3.0.1development

Distribution files

1 collected
Distribution 1

Source distribution

Source file
Checksums from source
{
  "shasum": "6154f69d5618f4675e9429879b59e6162ee5d985",
  "tarball": "https://registry.npmjs.org/@0xproject/utils/-/utils-1.0.9.tgz",
  "integrity": "sha512-pEtcjvfxk4yitZL8+6HE4OGvJWPmWdZhLV9ITD8EKXme+tfKvveQ3/Y/BWXRkA0l3wM3ZIqo/9ZK8sH3J5A45g==",
  "fileCount": 64,
  "unpackedSize": 75815,
  "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbpQdgCRA9TVsSAnZWagAAX8sP/2QhTUv4NdR8ZSyz/9Pk\nz5yiU5AhQ53o8lgdB8ohyM0zGv6zScpZvxfGGoJWmNuoMAP62mKgfXnuVNrw\nh+WZmGvgcu6W1tCjnZt7LJTZfs4ChdAye5F5/WWQAV7IvM2BoKBrlH2+F0CZ\nJj3JQhRNrkSjHnEz4CiDvFUF/wZH07wJQBFSVdjltw5XVEd+ObDq/vMsslFv\n65n3N7dpMm4amrmkGtxHJp8P38NCgfhlM2xboJ5qB3lp82xEiZp2aayRIuSg\nMyXyfjXnSQ8T4uU3Ig3KU+yH3QXfej/QBHNRRI/wEpTxTGKKbJp9R6Lkjdc2\nieqr1PrikQbdcQly9L5DswgC52oSwEn17ej8zuDJR9ZFl2eMkKOcaK0uLwIJ\nSgY2HwPrOtfh5ESojJAnV2+agidgJNfldSUc5qN//nsMJrFsfnUQjutXSiSc\nyvsuX+S5ikOTZCWiemTQ4cLtcoAgR6HLkuCau9iD/YYA8onaHQkCPp8BGYKz\noiVH7egREpzpdNGW4w5zflgqSCSriVkEVB+2YCUM8ka5YW0MCJDJITMLE2Jz\nzYcVPUYlCCQUQT9twyIx6GLg2YlUofY8arlmBGFH0eSCENhhMCkNHJeekvTB\n+hA7r6DMOwaTnGB271YZkQQJUqxrZ6XpefAn8sDSQTq4ZHdzCi4Y/ZGACYEx\nKgRn\r\n=rolg\r\n-----END PGP SIGNATURE-----\r\n",
  "signatures": [
    {
      "keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA",
      "sig": "MEUCIQDigBJDq5XB780lW6mWGXy0LJ2MNLeWjCPMS+kyM5fSOAIgf/7r5FSTgdRlup5Fl6ExSUcz09fVvwFWS3EvyQzuhWA="
    }
  ]
}

Repository

PENDING
0xproject/0x-monorepo

Shared repository data · GitHub

License detected in repository
Not collected

Repository

PENDING
0xproject/0x.js

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 21 Oct, 09:36 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:cdab7fd7095ed79a3940371ac835deb542e7e6d3d188ed6d2ed89c7d62e71941

Other collected versions

2.0.24 Oct2.0.028 Sept1.0.1125 Sept1.0.1025 Sept1.0.85 Sept1.0.727 AugView all collected versions →