← Back to Skills Marketplace
sunshine-del-ux

Chrome Extension Generator

by Sunshine-del-ux · GitHub ↗ · v1.0.0
cross-platform ⚠ suspicious
524
Downloads
0
Stars
2
Active Installs
1
Versions
Install in OpenClaw
/install chrome-extension-generator
Description
一键生成 Chrome 扩展程序模板,支持 Popup、Background Script、Content Script、Options 页面等多种类型。
README (SKILL.md)

Chrome Extension Generator

一键生成 Chrome 扩展程序模板,快速启动你的扩展开发。

功能

  • ⚡ 快速生成项目结构
  • 🎨 多种模板可选
  • 📝 完整的配置文件
  • 🧪 测试模板
  • 📖 生成 README
  • 🚀 支持 TypeScript

模板类型

模板 说明
basic 基础 Hello World
popup 带 Popup 界面
options 设置页面
content-script 内容脚本
background 后台脚本
full 完整功能扩展

使用方法

生成扩展

# 基本用法
chrome-extension-generator "扩展名称" "描述"

# 指定模板
chrome-extension-generator "My Extension" "描述" --template popup

# 指定技术栈
chrome-extension-generator "扩展" "描述" --template full --stack typescript

选项

选项 说明
--template, -t 模板类型
--stack, -s JavaScript/TypeScript
--output, -o 输出目录

输出结构

my-extension/
├── manifest.json
├── popup.html
├── popup.js
├── popup.css
├── background.js
├── content.js
├── options.html
├── options.js
├── icon.png
├── README.md
└── _locales/
    └── en/
        └── messages.json

示例

Popup 扩展

chrome-extension-generator "Focus Timer" "Pomodoro timer extension" --template popup

内容脚本扩展

chrome-extension-generator "Page Highlighter" "Highlight text on pages" --template content-script

完整扩展

chrome-extension-generator "All-in-One Tool" "Ultimate browser tool" --template full

manifest.json 示例

{
  "manifest_version": 3,
  "name": "My Extension",
  "version": "1.0.0",
  "description": "An amazing Chrome extension",
  "permissions": ["storage", "activeTab"],
  "action": {
    "default_popup": "popup.html"
  },
  "background": {
    "service_worker": "background.js"
  }
}

安装

# 无需依赖

开发流程

  1. 生成模板
  2. 修改 manifest.json
  3. 编写功能代码
  4. 本地加载扩展
  5. 测试并发布

发布到 Chrome Web Store

生成模板包含:

  • 发布检查清单
  • 上传截图模板
  • 商店描述模板

变现思路

  1. 付费模板 - 专业版模板
  2. 定制开发 - 为客户开发扩展
  3. 插件市场 - 建立扩展市场
  4. 广告收入 - 在扩展中展示广告
  5. 联盟营销 - 推广产品获取佣金

示例扩展

  • 广告拦截器
  • 密码管理器
  • 截图工具
  • 笔记工具
  • 社媒工具
  • 开发辅助工具

常用权限

权限 说明
storage 本地存储
activeTab 当前标签页
tabs 标签页管理
bookmarks 书签管理
history 历史记录
cookies Cookie 管理
webRequest 网络请求
Usage Guidance
This skill appears to do exactly what it claims: generate a Chrome extension scaffold locally. Before running: (1) choose or inspect the output directory because the script will create files there; (2) review the generated manifest.json and other files before loading/publishing the extension (change permissions like tabs, cookies, webRequest only if needed); (3) be aware the script uses a placeholder icon and minimal permissions by default; (4) the CLI option parsing in the script may not behave as documented — test flags on a sample run. No network calls or secret access were found, so the primary risk is accidental overwriting of files in the output path or uploading unreviewed code to the Chrome Web Store.
Capability Analysis
Type: OpenClaw Skill Name: chrome-extension-generator Version: 1.0.0 The `chrome-extension-generator.sh` script is vulnerable to shell injection. The `NAME` and `DESCRIPTION` arguments are directly interpolated into here-documents (e.g., `manifest.json`, `popup.html`, `README.md`) without proper sanitization. This allows an attacker to inject arbitrary shell commands by crafting malicious input for the extension name or description, leading to potential remote code execution. While this is a critical vulnerability, there is no evidence of intentional malicious behavior by the skill's author; it appears to be an implementation flaw rather than designed malware.
Capability Assessment
Purpose & Capability
Name, description, SKILL.md, and the included shell script are coherent: all describe and implement a local generator for Chrome extension templates. There are no unrelated required binaries, env vars, or network endpoints.
Instruction Scope
SKILL.md tells the agent/user to run a local CLI to generate files. The included script only creates files (manifest, HTML/JS, README) in the chosen output directory and does not access network, secrets, or unrelated system files. Minor note: the script's CLI option parsing appears buggy (it references $6/$7 and a loop condition on $# which may cause some flags to be ignored) — this is a functional issue, not a security one.
Install Mechanism
No install spec; this is instruction-only plus a bundled shell script. Nothing is downloaded or executed from remote URLs and no archives are extracted, so install risk is low.
Credentials
The skill requests no environment variables, credentials, or config paths. The generated manifest defaults to minimal 'storage' permission only; no unexpected credentials are accessed or required.
Persistence & Privilege
always is false and the skill does not request persistent elevated privileges or modify other skills or system-wide agent settings. It only writes files to the specified output directory.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install chrome-extension-generator
  3. After installation, invoke the skill by name or use /chrome-extension-generator
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release of chrome-extension-generator. - 一键生成多种 Chrome 扩展模板,包括 Popup、Background Script、Content Script、Options 页面等。 - 支持快速生成项目结构和完整配置文件,含 TypeScript 选项。 - 多种模板类型,适合不同扩展场景(basic、popup、options、content-script、background、full)。 - 自动生成 README、测试模板和发布相关内容。 - 简明命令行用法,支持自定义模板类型与输出目录。 - 附详细开发流程、变现思路及常用权限说明。
Metadata
Slug chrome-extension-generator
Version 1.0.0
License
All-time Installs 2
Active Installs 2
Total Versions 1
Frequently Asked Questions

What is Chrome Extension Generator?

一键生成 Chrome 扩展程序模板,支持 Popup、Background Script、Content Script、Options 页面等多种类型。 It is an AI Agent Skill for Claude Code / OpenClaw, with 524 downloads so far.

How do I install Chrome Extension Generator?

Run "/install chrome-extension-generator" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Chrome Extension Generator free?

Yes, Chrome Extension Generator is completely free (open-source). You can download, install and use it at no cost.

Which platforms does Chrome Extension Generator support?

Chrome Extension Generator is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Chrome Extension Generator?

It is built and maintained by Sunshine-del-ux (@sunshine-del-ux); the current version is v1.0.0.

💬 Comments