Refactors into a odule that exports lib, View, and Controller.