moai-platform-chrome-extension

Develop Chrome extensions with Manifest V3 service workers and APIs.

Updated Nov 28, 2024
One-click install
npx skills add https://github.com/desafin/Resource-Monitor-pyQT --skill moai-platform-chrome-extension-desafin
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: moai-platform-chrome-extension
Source: https://github.com/desafin/Resource-Monitor-pyQT/tree/main/.claude/skills/moai-platform-chrome-extension
Command: npx skills add https://github.com/desafin/Resource-Monitor-pyQT --skill moai-platform-chrome-extension-desafin

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides comprehensive guidance and tooling for developing robust, secure, and performant Chrome extensions using Manifest V3, addressing the complexities of service workers, content scripts, and modern Chrome APIs.

Core Features & Use Cases

  • Manifest V3 Development: Covers service workers, declarativeNetRequest, and the updated permissions model.
  • API Integration: Detailed reference for chrome.* APIs like storage, tabs, scripting, and sidePanel.
  • Security Best Practices: Guidance on CSP, input validation, and preventing XSS.
  • Use Case: Develop a Chrome extension that modifies web page behavior, manages user data securely, and integrates with Chrome's native features, all while adhering to Manifest V3 standards for publishing.

Quick Start

Use the moai-platform-chrome-extension skill to create a basic Manifest V3 service worker script.

Frequently Asked Questions about moai-platform-chrome-extension

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a Chrome extension with Manifest V3 and a service worker?

To build a Manifest V3 Chrome extension, configure a service worker in your manifest file to handle background logic. This skill guides you through creating service worker scripts, content scripts, and utilizing modern chrome.* APIs for robust browser extension architecture.

What is the difference between service workers and content scripts in Chrome extensions?

Service workers in Chrome extensions run in the background to manage events and logic, while content scripts inject directly into web pages to modify their behavior. This skill provides detailed references for implementing both effectively within Manifest V3.

How do I use declarativeNetRequest in a Manifest V3 browser extension?

DeclarativeNetRequest in a Manifest V3 browser extension allows you to block or modify network requests without blocking the main thread. This skill covers configuring declarativeNetRequest rules and navigating the updated permissions model.

Does Manifest V3 support the Chrome side panel API for browser extensions?

Yes, Manifest V3 supports the side panel API for building persistent UI surfaces alongside web content. This skill includes detailed reference material for integrating sidePanel, storage, tabs, and scripting APIs into your Chrome extension.

What are the security best practices for publishing a Chrome extension to the Web Store?

Security best practices for publishing a Chrome extension include enforcing strict Content Security Policy (CSP), validating inputs, and preventing XSS. This skill provides guidance on meeting Chrome Web Store publishing standards while adhering to Manifest V3 requirements.

How do I pass messages between a content script and a service worker?

Message passing between a content script and a service worker uses the chrome.runtime API to send and listen for events. This skill covers implementing message passing to coordinate page modifications with background logic in your Chrome extension.