diff --git a/README.md b/README.md index 8a493ef..21745b2 100644 --- a/README.md +++ b/README.md @@ -7,20 +7,26 @@ which implements the [Generic JSON RPC](https://github.com/ethereum/wiki/wiki/JS +[Documentation](https://github.com/ethereum/wiki/wiki/JavaScript-API) + ## Installation ### Node.js - npm install ethereum.js + $ npm install ethereum.js + +### Meteor.js + + $ meteor add ethereum:js ### For browser Bower - bower install ethereum.js + $ bower install ethereum.js Component - component install ethereum/ethereum.js + $ component install ethereum/ethereum.js * Include `ethereum.min.js` in your html file. * Include [bignumber.js](https://github.com/MikeMcl/bignumber.js/) @@ -30,9 +36,9 @@ Require the library: var web3 = require('web3'); -Set a provider (QtSyncProvider, HttpSyncProvider) +Set a provider (QtSyncProvider, HttpProvider) - web3.setProvider(new web3.providers.HttpSyncProvider()); + web3.setProvider(new web3.providers.HttpProvider('http://localhost:8545')); There you go, now you can use it: @@ -44,6 +50,7 @@ var balance = web3.eth.getBalance(coinbase); For another example see `example/index.html`. + ## Contribute! ### Requirements diff --git a/package.js b/package.js new file mode 100644 index 0000000..f79bd5e --- /dev/null +++ b/package.js @@ -0,0 +1,23 @@ +Package.describe({ + name: 'ethereum:js', + version: '0.0.15-rc1', + summary: 'Ethereum JavaScript API, middleware to talk to a ethreum node over RPC', + git: 'https://github.com/ethereum/ethereum.js', + // By default, Meteor will default to using README.md for documentation. + // To avoid submitting documentation, set this field to null. + documentation: 'README.md' +}); + +Package.onUse(function(api) { + api.versionsFrom('1.0.3.2'); + + api.use('3stack:bignumber@2.0.0', 'client'); + + api.addFiles('dist/ethereum.js', 'client'); +}); + +// Package.onTest(function(api) { +// api.use('tinytest'); +// api.use('test'); +// api.addFiles('test-tests.js'); +// }); diff --git a/package.json b/package.json index 53db610..14aa118 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "ethereum.js", "namespace": "ethereum", "version": "0.0.15", - "description": "Ethereum Compatible JavaScript API", + "description": "Ethereum JavaScript API, middleware to talk to a ethreum node over RPC", "main": "./index.js", "directories": { "lib": "./lib"