Like we've drupal_add_css() , there should be something like drupal_remove_css. An alternative way to module / theme developer to speed up by removing unnecessary css/js.

To Remove extra css code such as,

@import "/modules/node/node.css";
@import "/modules/system/defaults.css";
@import "/modules/system/system.css";
@import "/modules/user/user.css";

@import "/sites/all/modules/cck/content.css";
@import "/sites/all/modules/cck/fieldgroup.css";

@import "/themes/garland/style.css";

I'm not in favor that every custom developer should remove, but one should have option to remove it.

Comments

marc.groth’s picture

Agreed!

sun.core’s picture

Version: 7.x-dev » 8.x-dev
jhedstrom’s picture

Issue summary: View changes
Status: Active » Closed (works as designed)

We have hook_css_alter() for just this reason.