Cache for JS and CSS also

Made cache polymorphic (we will parse new entities like pages)