Fix page rendering by using script caching