Changing view generator from constructor to object

Maybe? (just quick fix, haven't actually tried it)