JSFiddle - React, Tailwind, and code Playground

by Outrora

Babel + JSX

Transactions.prototype.setTransactions = function(txs) {
  if (!(txs instanceof Array))
    return false;

  for (let tx of txs) {
    this.setTransaction(tx);
  }
	
	return this;
}
Transactions.prototype.setTransactions.fromRaws = function(raws) {
	console.log(raws)
}
Transactions.prototype.setTransaction = function(tx) {
  if (!(tx instanceof Transaction))
		return false

  this.transactions[this.transactions.length] = transaction;
}
function Transactions() {
  this.transactions = [];
}


Transaction.prototype.fromRaw = function(raw) {
  if (!raw)
    return false;
  this.transaction = parseBcoinTx(raw)
}
function Transaction() {
  this.transaction = undefined;
}

const test = new Transactions();

test.setTransactions.fromRaws('OIAOSIDOI');