Skip to content
Snippets Groups Projects
Commit f0541cf3 authored by adcpm's avatar adcpm
Browse files

- Change default WebSocket and set example with CDN

parent 952a5bf7
No related branches found
No related tags found
No related merge requests found
# Steem.js
SteemJS the JavaScript API for Steem blockchain
Steem.js the JavaScript API for Steem blockchain
## Documentation
Here is full documentation: https://github.com/adcpm/steem/tree/master/doc
......@@ -14,12 +14,24 @@ steem.getAccounts(['ned', 'dan'], function(err, response){
</script>
```
## CDN
http://cdn.steemjs.com/lib/steem.min.js
https://cdn.steemjs.com/lib/steem.min.js
```html
<script src="//cdn.steemjs.com/lib/steem.min.js"></script>
```
## Server
## Install
```
$ npm install steem --save
```
## WebSockets
wss://steemit.com/wspa By @steemit (Set By Default)
wss://this.piston.rocks By @xeroc
wss://node.steem.ws By @xerox And @jesta
## Examples
### Get Accounts
```js
......
# To Do
### - Multi Requests On Browser
### - Get Api By Name (No Local Var Storage)
### - Broadcast Post / Comment / Vote
\ No newline at end of file
......@@ -2,11 +2,11 @@
<html lang="en">
<head>
<meta charset="UTF-8">
<title>SteemJS</title>
<title>Steem.js</title>
</head>
<body>
<script src="./steem.min.js"></script>
<script src="//cdn.steemjs.com/lib/steem.min.js"></script>
<script>
steem.getAccounts(['ned', 'dan'], function(err, response){
console.log(err, response);
......
This diff is collapsed.
var WebSocket = require('ws');
var Steem = function(url){
this.url = url || 'wss://node.steem.ws';
this.url = url || 'wss://steemit.com/wspa';
this.apiIds = {
'database_api': 0,
'login_api': 1,
......
This diff is collapsed.
{
"name": "steem",
"version": "0.2.17",
"version": "0.2.18",
"description": "Steem.js the JavaScript API for Steem blockchain",
"main": "index.js",
"scripts": {
......
var Steem = require('./lib/steem'),
steem = new Steem('wss://steemit.com/wspa');
steem = new Steem();
steem.login('******', '****************', function(err, result) {
console.log(result);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment