Testing Routes With Mocha and Chai

Testing Routes with Mocha and Chai While working on a restful api built with express I was trying to find an easy way to test my routes along with my unit tests using chai so I came up with a simple typescript class to fake http requests and responses so that I can verify that the request status and response body are set correctly and figured I’d share it here.

Continue reading

Communicating Between IOS And React

Communicating Between IOS And REACT Every once in a while when writing applications for Iphone you may need to load a component from a web application into a webview and have communication between your ios application and your web app. I ran into this recently when I wanted to reuse an interactive map I wrote for a web application using javascript and react. I found it difficult to find a straightforward tutorial of how to communicate from swift to javascript and then communicate from javascript to swift.

Continue reading