fec-web-workers

fec-web-workers is a skill for Claude Code from bovinphang/frontend-craft. It costs 78 tokens per session (511 once invoked), scanned A, original, MIT.

A Web Worker moves expensive JavaScript calculations into a separate browser thread so the page's main thread can handle input, scrolling, and animation. Workers cannot directly access the page's DOM.

In plain words
What is it for?
Use it to design or troubleshoot Web Workers, SharedWorkers, worker pools, Comlink communication, transferable data, and worker integration with Vite or Webpack.
Why use it?
It helps prevent heavy parsing, image processing, encryption, or other calculations from making the interface feel stuck. It also covers how the page sends messages and cleans up workers safely.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the frontend-craft plugin — 56 skills, 11 commands, 14 agents, 5 hooks, 6 MCP servers shipped together

Good fit Use it to design or troubleshoot Web Workers, SharedWorkers, worker pools, Comlink communication, transferable data, and worker integration with Vite or Webpack.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/bovinphang/frontend-craft/fec-web-workers
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add bovinphang/frontend-craft --skill fec-web-workers
Clone the repo
git clone --depth 1 https://github.com/bovinphang/frontend-craft

Made for: Claude Code.

Or install frontend-craft, the plugin that ships this one along with the rest of its 56 skills, 11 commands, 14 agents, 5 hooks, 6 MCP servers.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for fec-web-workers

README.md
[![agentmods](https://agentmods.dev/badge/skills/bovinphang/frontend-craft/fec-web-workers/github.svg)](https://agentmods.dev/skills/bovinphang/frontend-craft/fec-web-workers)
Your own site
<a href="https://agentmods.dev/skills/bovinphang/frontend-craft/fec-web-workers"><img src="https://agentmods.dev/badge/skills/bovinphang/frontend-craft/fec-web-workers/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for fec-web-workers

Your own site · 80×15
<a href="https://agentmods.dev/skills/bovinphang/frontend-craft/fec-web-workers"><img src="https://agentmods.dev/badge/skills/bovinphang/frontend-craft/fec-web-workers.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 78 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 511 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00078 $0.00511
Opus 5 $0.00039 $0.00255
Sonnet 5 $0.00016 $0.00102
Haiku 4.5 $0.00008 $0.00051

Measured 5d ago against content hash 73946e82d72d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

fec-web-workers scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

localized/zh-CN/skills/fec-web-workers/SKILL.md · 36 lines

What it actually says

Web Workers

用途

把昂贵计算移出主线程,保持输入、滚动和动画响应。

流程

  1. 先确认瓶颈:任务超过约 10ms、用户输入延迟明显、FPS 下滑或大文件解析/图像处理/加密计算才考虑 Worker。
  2. 选择通信模型:简单任务用 postMessage,函数式 RPC 用 Comlink,大量并行小任务用 Worker pool,跨 Tab 同步用 SharedWorker。
  3. 设计消息协议:请求/响应类型、错误类型、取消或超时策略都要明确。
  4. 传大对象时优先 Transferable Objects;不要让结构化克隆吞掉 Worker 带来的收益。
  5. 在组件或页面卸载时 terminate(),并通过 Profiler、Performance 面板或 FPS 指标验证主线程改善。

详细参考

  • 需要原生 Worker 文件、构建工具导入、React 生命周期封装和清理示例时,加载 references/basic-worker.md
  • 需要 Transferable Objects、Comlink、Worker pool、SharedWorker、CSP 和 SharedArrayBuffer 注意事项时,加载 references/advanced-workers.md

约束

  • Worker 内不能访问 DOM、windowdocumentalert() 或同步 localStorage
  • 高频通信可能比主线程计算更慢;先测量再拆分。
  • Worker 文件必须同源加载,并受 worker-src CSP 限制。
  • 大型二进制数据优先 transfer,transfer 后原引用会失效。
  • 每个 Worker 有独立 JS 堆,必须主动管理生命周期和内存。

预期输出

计算密集型操作在后台线程执行,主线程输入和滚动恢复流畅,错误与取消路径明确,Worker 在卸载时被终止且无内存泄漏。

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 36 lines · 78 tokens per session scan A 73946e82d72d

Subscribe to this mod's changes

fec-web-workers is a skill published in the GitHub repository bovinphang/frontend-craft (21 stars, last pushed 7d ago), licensed MIT. It adds 78 tokens to every session and 511 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

create-mobile-app

Use when the user wants to start a new Power Apps mobile app (Expo / React Native / TypeScript, targeting iOS and Android) from scratch.

microsoft/power-platform-skills · 35 tokens

app-builder

(Preview) Builds and edits a model-driven Power Apps app from a natural-language intent — tables, columns, relationships, adaptive forms with sub-grids, views, Choice-column charts, generative page intents for overview/dashboard surfaces (page .tsx generated in generate-pages after plan approval), and an app module +…

microsoft/power-platform-skills · 210 tokens

create-site

Creates a new Power Pages code site (SPA) using React, Angular, Vue, or Astro. Guides through the full process from initial concept to deployed site: requirements discovery, scaffolding, component planning, design, implementation, validation, and deployment. Use when the user wants to create, build, or scaffold a new…

microsoft/power-platform-skills · 73 tokens

test-site

Tests a deployed, activated Power Pages site at runtime using browser-based navigation, page crawling, and API request verification via Playwright. Use when the user wants to test, verify, or smoke-test their deployed site.

microsoft/power-platform-skills · 46 tokens

genpage

Creates, updates, and deploys Power Apps generative pages for model-driven apps using React v17, TypeScript, and Fluent UI V9. Orchestrates specialist agents for planning, entity creation, and code generation. Use it when user asks to build, retrieve, or update a page in an existing Microsoft Power Apps model-driven…

microsoft/power-platform-skills · 140 tokens

migrate-bootstrap

Migrates a traditional Power Pages site from Bootstrap 3 to Bootstrap 5. Downloads the site, runs the pac pages bootstrap-migrate engine, reviews the change report, applies AI-assisted fixes for the residual hierarchy/CSS changes the engine only flags, uploads the migrated site (which auto-enables the Bootstrap 5…

microsoft/power-platform-skills · 116 tokens