Javascript
Using JWTs for Authentication in RESTful Applications
The problem Applications built using the MEAN stack typically use Node, MongoDB and Express on the back end to implement business logic fronted by a RESTful interface. Most of the work is done on the back end, and Angular serves as an enhanced view in the MVC (model-view-controller) pattern. Keeping business rules and logic on […]
Composing the results of nested asynchronous calls in Javascript
Grokking asynchronicity One of the toughest things to get your head around in Javascript is how to handle nested asynchronous calls, especially when a function depends on the result of a preceding one. I see this quite a bit in my software engineering course where teams are required to synthesize new information from two distinct third-party data […]
Dogfooding: Defining roles in an MVC architecture with internal APIs
Here’s a copy of the talk I did recently at Boston University discussing how to implement a clean MVC architecture for web apps, with a decoupled front end, using an internal API. Abstract: The architectural design of an application often comes down to a single question: Where is the work done? Traditional client-server applications answer […]
Using Javascript Promises to synchronize asynchronous methods
The asynchronous, non-blocking Javascript runtime can be a real challenge for those of us who are used to writing in a synchronous style in languages such as Python of Java. Especially tough is when we need to do several inherently asynchronous things in a particular order…maybe a filter chain…in which the result of a preceding […]