跳到内容

Pagelean – Conditional Script and Style Loading

v1.2.3

WPPoland (Mariusz Szatkowski) · 2026年10月6日 上架

Dequeue individual scripts and styles on the pages that do not need them. Fewer requests, lighter pages, faster loads - using WordPress core.

正在使用
10 以下
评分
5.0 / 5
累计下载
638
最近更新
2026年11月24日
1 条评价需要 WordPress 6.5+已测试到 7.1.5PHP 8.1+

截图

The rule table: remove a handle on the pages that do not need it.
The rule table: remove a handle on the pages that do not need it.

Most plugins load their CSS and JavaScript on every page, even where their feature never appears. A contact form script on your checkout, a slider stylesheet on your blog posts, a social-share bundle on your privacy policy. That weight slows every visit.

Pagelean lets you remove a specific script or style from exactly the pages where it is not needed – front page, blog index, single posts and pages (by ID), single entries of a post type, the WooCommerce shop, product, cart and checkout pages, or by device. It uses the standard WordPress enqueue system (wp_dequeue_script / wp_dequeue_style), so there is no page-builder lock-in and nothing proprietary to learn.

What it does

  • Remove any registered script or style handle by name.
  • Choose where it is removed: everywhere, the front page, the blog posts index, single posts/pages (by ID), single entries of any public post type, the WooCommerce shop, product, cart or checkout page (when WooCommerce is active), or only mobile / only desktop.
  • Test mode: the rules apply only to logged-in administrators while everyone else gets the untouched page, with a notice in the admin until you turn it off.
  • Dequeue by default; tick “Also deregister” on a rule only when you want the handle gone even where another script depends on it.
  • Autocomplete from the handles your front-end pages actually load, recorded while you browse the site as an administrator (up to 500, with their source file).
  • Runs late on the front end so it removes handles reliably, and never touches the admin.

What it does not do

It does not minify, combine or defer. It removes what you tell it to remove – nothing automatic, nothing hidden. Removing a handle that another script depends on can break functionality, so change one rule at a time and check the front end.

Part of the Plogins family

Pagelean is one of a family of small, focused WordPress and WooCommerce plugins by WPPoland. Learn more at plogins.com.

Plums

按场景查找 WordPress 插件。安装量、评分和兼容版本来自官方目录。

导航

说明

WordPress 是 WordPress Foundation 的商标。本站与 WordPress Foundation、Automattic 没有隶属关系。这里不托管插件文件,下载和安装以 WordPress.org 上的页面为准。

© 2026 Plums