Build with Colony: The Colony JavaScript client
Clone or download
ryanchristo Merge pull request #332 from JoinColony/maintenance/client-fixes-and-…
…additions

Update and add contract client methods
Latest commit 8b47ab5 Jan 15, 2019

README.md

colonyJS

colonyJS is a JavaScript client for the Colony Network. It provides a high-level API for interacting with the Colony Network smart contracts.

To learn more about Colony, you can visit the website or read the white paper.

Documentation

Please see the full documentation with detailed examples and explanations.

Contributing

We welcome all contributions to colonyJS. Please read our contributing guidelines.

Development

colonyJS is a monorepo-based project. A monorepo is simply a common repository for all npm modules of a certain scope, sharing common modules and dev environments. You can learn more about monorepos here.

We're using yarn workspaces and lerna to manage this monorepo.

Flow typing is also use throughout this repo.

Yarn workspaces

To use yarn workspaces you'll have to activate it in your yarn settings like so:

yarn config set workspaces-experimental true

Then a yarn in the root directory will install all necessary packages (also in packages/*) and link the interdependencies.

To add a dependency to a particular package, just run

yarn add [packagename]

in your packages/* directory.

Lerna

We're using lerna to publish the packages to npm and to run commands inside the repositories. We're running in lerna's independence mode, meaning the modules won't all have the same version number and are versioned independently.

To run a command (e.g. the build command) in all packages just do:

lerna run build

which will call the npm script for build (more info here).

To publish modules to npm, run:

lerna publish

and it will guide you through the publish process.

To run a command for a single package, lerna ought to be used in order for the environment to resolve the common devDependencies:

lerna run --scope=@colony/my-package-name test