aboutsummaryrefslogtreecommitdiffstats
path: root/packages/abi-gen/README.md
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2018-03-04 02:11:09 +0800
committerFabio Berger <me@fabioberger.com>2018-03-04 02:11:09 +0800
commitc797c720be1bf77b520c695ff2cb6940e9d9dd14 (patch)
tree5cf0ff756a08046cb25b47b24103e90d8f5f0657 /packages/abi-gen/README.md
parent244c148a80d555bfb67cb83bb2d82a44b5aca68c (diff)
downloaddexon-sol-tools-c797c720be1bf77b520c695ff2cb6940e9d9dd14.tar.gz
dexon-sol-tools-c797c720be1bf77b520c695ff2cb6940e9d9dd14.tar.zst
dexon-sol-tools-c797c720be1bf77b520c695ff2cb6940e9d9dd14.zip
Update all mentions of the repo name being `0x.js` to `0x-monorepo`
Diffstat (limited to 'packages/abi-gen/README.md')
-rw-r--r--packages/abi-gen/README.md8
1 files changed, 4 insertions, 4 deletions
diff --git a/packages/abi-gen/README.md b/packages/abi-gen/README.md
index 1188bd437..5232e59ce 100644
--- a/packages/abi-gen/README.md
+++ b/packages/abi-gen/README.md
@@ -4,8 +4,8 @@ This package allows you to generate TypeScript contract wrappers from ABI files.
It's heavily inspired by [Geth abigen](https://github.com/ethereum/go-ethereum/wiki/Native-DApps:-Go-bindings-to-Ethereum-contracts) but takes a different approach.
You can write your custom handlebars templates which will allow you to seamlessly integrate the generated code into your existing codebase with existing conventions.
-For an example of the generated [wrapper files](https://github.com/0xProject/0x.js/tree/development/packages/0x.js/src/contract_wrappers/generated) check out 0x.js.
-[Here](https://github.com/0xProject/0x.js/tree/development/packages/0x.js/contract_templates) are the templates used to generate those files.
+For an example of the generated [wrapper files](https://github.com/0xProject/0x-monorepo/tree/development/packages/0x.js/src/contract_wrappers/generated) check out 0x.js.
+[Here](https://github.com/0xProject/0x-monorepo/tree/development/packages/0x.js/contract_templates) are the templates used to generate those files.
## Installation
@@ -36,14 +36,14 @@ The abi file should be either a [Truffle](http://truffleframework.com/) contract
## How to write custom templates?
-The best way to get started is to copy [0x.js templates](https://github.com/0xProject/0x.js/tree/development/packages/0x.js/contract_templates) and start adjusting them for your needs.
+The best way to get started is to copy [0x.js templates](https://github.com/0xProject/0x-monorepo/tree/development/packages/0x.js/contract_templates) and start adjusting them for your needs.
We use [handlebars](http://handlebarsjs.com/) template engine under the hood.
You need to have a master template called `contract.mustache`. it will be used to generate each contract wrapper. Although - you don't need and probably shouldn't write all your logic in a single template file. You can write [partial templates](http://handlebarsjs.com/partials.html) and as long as they are within a partials folder - they will be registered and available.
## Which data/context do I get in my templates?
For now you don't get much on top of methods abi, some useful helpers and a contract name because it was enough for our use-case, but if you need something else - create a PR.
-See the [type definition](https://github.com/0xProject/0x.js/tree/development/packages/abi-gen/src/types.ts) of what we pass to the render method.
+See the [type definition](https://github.com/0xProject/0x-monorepo/tree/development/packages/abi-gen/src/types.ts) of what we pass to the render method.
## Output files