Tx-conversion-js

I’ve been wanting to continue the work on the BTCR Playground and have taken to looking at the backend scripts in more detail to make it easier to extend with different methods to return tx data. One of the problems that I had was figuring out what the backend scripts do and making sure that it is up-to-date fixing npm vulnerabilities.

I’ve started with tx-conversion-js and have picked it apart to find out what actions it performs and how. I took what was there and have reworked it in the hope that it will make it easier to extend and maintain, including extensive commenting in the code that is used to automatically generate documentation via JSDOC. My hope is that this documentation will help others to contribute.

I’ve implemented the change for https://github.com/WebOfTrustInfo/txref-conversion-js/issues/14 in this version so results differ a little. And I still need to get transactions passed back in the previous format but don’t see that being much of an issue.

I wouldn’t consider myself a software engineer so I’d really appreciate some feedback / code review on the work that I’ve done here: https://github.com/hawkmauk/txref-conversion-js
In the most part it should be backwards compatible with the existing code with a txrefConverter.js script that can expose the same methods as the original. I’m still working on getting the test cases passing for this but have passing tests for the other code.