woocommerce-performance

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

WooCommerce Performance

WooCommerce 性能

Post Cache Priming — cache-priming.md

文章缓存预加载 — cache-priming.md

Use when writing or reviewing code that loads collections of post-based objects (products, orders) or renders product lists with images. Covers
_prime_post_caches()
usage patterns — both as a generation guide (apply these patterns when writing new code) and a review guide (flag missing priming in existing code).
适用于编写或审查加载基于文章类型的对象集合(产品、订单)或渲染带图片的产品列表的代码。涵盖
_prime_post_caches()
的使用模式——既是编写新代码时的参考指南(编写新代码时应用这些模式),也是代码审查指南(标记现有代码中缺失的预加载操作)。

Options Cache Priming — options-cache-priming.md

选项缓存预加载 — options-cache-priming.md

Use when writing or reviewing code that reads multiple non-autoloaded options in a loop or method. Covers
wp_prime_option_caches()
usage patterns for static key lists, derivable key patterns, and dynamically extracted key sets (excluding autoloaded options, which are already in cache).
适用于编写或审查在循环或方法中读取多个非自动加载选项的代码。涵盖
wp_prime_option_caches()
针对静态键列表、可推导键模式以及动态提取键集合(排除已在缓存中的自动加载选项)的使用模式。

SQL Query Patterns — sql-query-patterns.md

SQL查询模式 — sql-query-patterns.md

Use when writing or reviewing any SQL query in WooCommerce PHP code. Covers: redundant posts joins, fan-out JOIN on
wp_term_relationships
, N-query loops, OR index-merge, cross-product meta conditions, multi-fan join decoupling, WooCommerce lookup table preference (
wc_product_meta_lookup
,
wc_product_attributes_lookup
), and MIN/MAX full-scan elimination.
适用于编写或审查WooCommerce PHP代码中的任何SQL查询。涵盖:冗余文章表连接、
wp_term_relationships
表的扇出连接、N次查询循环、OR索引合并、笛卡尔积元数据条件、多扇出连接解耦、WooCommerce查询表优先使用(
wc_product_meta_lookup
、
wc_product_attributes_lookup
)以及MIN/MAX全扫描消除。