This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Created by Chih.Lun.Kang | |
| // 網路上找的範例大部分都不能用,後來嘗試數次只有這方法可行 | |
| // 主網的appid => 539ab33xxxx,要去Infura申請,在上面建立一個project | |
| // #### NOTE #### : 要特別注意本身轉帳的帳號要儲備足夠數量的 eth 跟 btc | |
| // #### 注意 #### : 目前使用人工轉換儲值手續費,建議在幣價好的時候一次換匯才划算 | |
| const USDTJSON = require('./build/contracts/USDT.json') | |
| const Web3 = require('web3') | |
| const Tx = require('ethereumjs-tx').Transaction |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Author: Pieter Noordhuis | |
| # Description: Simple demo to showcase Redis PubSub with EventMachine | |
| # | |
| # Update 7 Oct 2010: | |
| # - This example does *not* appear to work with Chrome >=6.0. Apparently, | |
| # the WebSocket protocol implementation in the cramp gem does not work | |
| # well with Chrome's (newer) WebSocket implementation. | |
| # | |
| # Requirements: | |
| # - rubygems: eventmachine, thin, cramp, sinatra, yajl-ruby |