add caching to views