ecommerce-caching
БесплатноБез исполняемых скриптовНе проверенImprove store performance with a layered caching strategy — CDN edge caching, Redis application cache, and smart cart-aware invalidation
от finsilabs★ 69 звёзд на GitHubОб этом скилле
E-commerce Caching
Overview
Implement multi-layer caching for e-commerce applications covering CDN edge caching, application-level caching (Redis), and full-page caching with cart-aware invalidation. This skill addresses the unique challenges of caching commerce pages — personalized content (cart count, logged-in state), frequently changing inventory and prices, and the need for instant cache purging when products or prices change.
When to Use This Skill
- When product and collection pages are slow due to database queries and API calls
- When implementing a CDN or edge caching strategy for a storefront
- When adding Redis caching for product data, inventory, and session management
- When building cache invalidation logic that reacts to product, price, or inventory changes
- When optimizing time-to-first-byte (TTFB) for high-traffic sale events
Core Instructions
Step 1: Determine your platform and what you can control
| Platform | What's Managed For You | What You Control |
|---|---|---|
| Shopify | CDN, full-page caching, server infrastructure | Liquid template efficiency, image optimization, app performance, HTTP cache headers on custom routes |
| WooCommerce | Nothing (you own the server) | Everything: page cache, object cache, CDN, database queries |
| BigCommerce | CDN, full-page caching, server infrastructure | Theme performance, image optimization, app overhead |
| Custom / Headless | Nothing (you own the server) | Everything: CDN configuration, Redis, Varnish, application cache, invalidation |
Step 2: Platform-specific caching configuration
Shopify
Shopify handles CDN and full-page caching automatically. Your optimization levers are:
Theme performance (Liquid):
- Reduce the number of Liquid
{% render %}calls in your product and collection templates — each render tag adds rendering time - In Online Store → Themes → Edit code, avoid loops that query the catalog repeatedly; use
{% liquid %}blocks for conditional logic - Enable Shopify's Lazy loading for product images in Theme settings — this prevents below-fold images from blocking page load
App performance:
- Audit your installed apps in Apps → App usage or with Shopify's Storefront Performance dashboard (Online Store → Themes → View report)
- Apps that inject scripts into every page (especially checkout) can add 200–500ms per page load
- Remove unused apps — even inactive apps with installed scripts slow down your store
- For apps that add storefront JavaScript, check if they support Delayed loading (loads after page interactive) in their settings
CDN image optimization: Shopify automatically serves images via its CDN with WebP conversion and responsive sizing. To ensure you're using this:
- Always use Shopify's Liquid
img_urlfilter to generate image URLs — this routes through the Shopify CDN - Add
widthandheightattributes to all<img>tags in your Liquid to prevent Cumulative Layout Shift - In Online Store → Themes → Customize → Theme settings → Images, verify lazy loading is enabled
WooCommerce
WooCommerce runs on your hosting infrastructure. Implement a three-layer caching stack:
Layer 1: PHP Object Cache (Redis)
- Your hosting must support Redis (WP Engine, Kinsta, Cloudways, and most managed WordPress hosts do — check your control panel)
- Install Redis Object Cache (free, wordpress.org)
- Go to Settings → Redis and click Enable Object Cache
- This caches all WordPress and WooCommerce database queries in Redis; most stores see 60–80% reduction in database load
Layer 2: Page Cache
- Install WP Rocket ($59/yr — the most effective WordPress page cache plugin) or LiteSpeed Cache (free, if your host uses LiteSpeed)
- In WP Rocket: go to Cache → Enable caching for logged-in WordPress users — keep this off; cached pages should only serve anonymous visitors
- Enable Preload cache: WP Rocket will crawl and pre-cache your product and shop pages
- Enable Separate cache file for mobile if your mobile and desktop layouts differ significantly
Layer 3: CDN
- Configure Cloudflare (free tier available) as your CDN:
- Add your domain to Cloudflare and point DNS to Cloudflare's nameservers
- Install the Cloudflare WordPress plugin to enable cache purging from wp-admin
- Set Caching level to Standard in Cloudflare dashboard
- In WP Rocket, enable Cloudflare integration in the CDN settings — this allows WP Rocket to purge Cloudflare cache when you update products
- Or use BunnyCDN ($1/mo for bandwidth) which integrates with WP Rocket natively
Cache invalidation for WooCommerce:
WP Rocket and LiteSpeed Cache automatically purge cached pages when products are updated via the wp-admin. For programmatic updates, add this to your child theme's functions.php:
// Purge product page cache when inve
Установить ecommerce-caching в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
claude-codecursorgemini-clicopilotcodex-clikiroopencodeВложенные файлы
FAQ
Что делает скилл ecommerce-caching?
Improve store performance with a layered caching strategy — CDN edge caching, Redis application cache, and smart cart-aware invalidation
Как установить скилл ecommerce-caching?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл ecommerce-caching запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic