Better version - no need to specify any external functions for a view