Firefox Devtoolsのロゴ

Firefox Devtools

組織
zenobi-us
firefox-devtools

Enables Firefox remote debugging workflows, when browser automation or protocol-level Firefox inspection is needed, resulting in configured Firefox RDP access and repeatable debugging steps.

概要

公開者zenobi-us
リポジトリdotfiles
スキル名firefox-devtools
スター
67
フォーク
6
同梱ファイル
10
ライセンスMIT
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 10個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    zenobi-usがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキルFirefox DevtoolsをTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/zenobi-us/dotfiles/tree/master/files/devtools/agent/bundles/developer/skills/browsers/firefox-devtools
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/zenobi-us/dotfiles.git /tmp/dotfiles
mkdir -p .claude/skills
cp -r /tmp/dotfiles/files/devtools/agent/bundles/developer/skills/browsers/firefox-devtools .claude/skills/firefox-devtools
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでFirefox Devtoolsを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあると、モデルが自動的にFirefox Devtoolsを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Firefox Devtoolsは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、未使用のスキルにはコストがかかりません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

Firefox DevTools Integration Skill

Purpose

Run scripts/analysis.ts directly for test coverage analysis. Run scripts/test-analysis.ts directly to execute the Bun test suite. This skill enables seamless integration of Firefox Remote Debugging Protocol (RDP) for development workflows, similar to Chrome DevTools integration. It configures Firefox to accept remote debugging connections and provides tooling to interact with browser instances programmatically.

Prerequisites

  • Firefox 55+ (RDP support)
  • Port 6000 available (or custom port)
  • Remote debugging enabled
  • Development environment setup

Core Concepts

Firefox Remote Debugging Protocol (RDP)

Unlike Chrome's Chrome DevTools Protocol (CDP), Firefox uses its own RDP over WebSocket connections on port 6000 by default.

Key differences from Chrome:

  • Transport: WebSocket instead of WebSocket (similar, but different protocol implementation)
  • Default Port: 6000 (vs Chrome's 9222)
  • Connection Type: Target-agnostic (works with tabs, workers, extensions)
  • Authentication: Optional origin header validation
  • Tools Available: Inspector, Debugger, Console, Network, Performance, Storage

Configuration Modes

1. Standard Remote Debugging

Enable Firefox to accept remote debugging connections:

bash
firefox --remote-debugging-port 6000
2. Profile-Based Configuration

Create a Firefox profile with debugging pre-enabled:

bash
firefox -profile /path/to/profile -remote-debugging-port 6000
3. Environment Variable Setup
bash
export MOZ_PROFILER_STARTUP=1
export MOZ_REMOTE_DEBUG_PORT=6000
firefox

Implementation Steps

Step 1: Enable Remote Debugging

javascript
// Via about:config in Firefox
devtools.debugger.remote-enabled = true
devtools.chrome.enabled = true
devtools.debugger.prompt-connection = false

Step 2: Connect DevTools Client

javascript
// Node.js example using RDP client
const { RDPClient } = require('firefox-rdp');

const client = new RDPClient({
  host: 'localhost',
  port: 6000
});

client.connect()
  .then(() => console.log('Connected to Firefox'))
  .catch(err => console.error('Connection failed:', err));

Step 3: Programmatic Debugging

Access browser capabilities through RDP:

  • Inspector: DOM manipulation and inspection
  • Debugger: JavaScript breakpoints and stepping
  • Console: Execute scripts and view logs
  • Network: Monitor and intercept requests
  • Performance: Profile runtime performance
  • Storage: Access cookies, localStorage, sessionStorage

Integration Points

1. Mise Configuration

toml
[tools.firefox-debug]
version = "latest"
env = { MOZ_REMOTE_DEBUG_PORT = "6000" }

2. Comtrya Provisioning

yaml
action: shell
description: "Enable Firefox Remote Debugging"
command: |
  firefox-preferences \
    --set devtools.debugger.remote-enabled=true \
    --set devtools.chrome.enabled=true \
    --set devtools.debugger.prompt-connection=false

3. MCPort Configuration

Similar to chrome-devtools-mcporter, create Firefox equivalents:

json
{
  "firefox-debug": {
    "binary": "firefox",
    "args": ["--remote-debugging-port", "6000"],
    "port": 6000,
    "protocol": "rdp"
  }
}

Common Tasks

Inspect DOM Elements

javascript
const { Inspector } = await client.getActor('inspector');
const nodeActor = await inspector.querySelector('body');
const attributes = await nodeActor.getAttributes();

Set JavaScript Breakpoint

javascript
const { Debugger } = await client.getActor('debugger');
const script = await debugger.getScript({ url: 'file.js' });
await debugger.setBreakpoint({ location: { scriptId: script.id, line: 10 } });

Execute Console Commands

javascript
const { Console } = await client.getActor('console');
const result = await console.evaluateJS('window.location.href');
console.log(result.value);

Monitor Network Requests

javascript
const { NetworkMonitor } = await client.getActor('networkMonitor');
networkMonitor.on('request', (req) => {
  console.log(`${req.method} ${req.url}`);
});

Tools and Libraries

RDP Clients

  • firefox-rdp - Raw RDP protocol client
  • webext-run - Run and debug WebExtensions
  • firefox-launcher - Programmatic Firefox launching

Integration Tools

  • firefox-devtools-adapter - Bridge between CDP and RDP
  • debug-protocol-converter - Convert between Chrome CDP and Firefox RDP

Development Tools

  • Firefox DevTools itself (can connect to remote instances)
  • Visual Studio Code extensions (Debugger for Firefox)
  • WebStorm/IntelliJ built-in Firefox debugging

Troubleshooting

Connection Refused

Cause: Firefox not listening on RDP port Solution:

bash
# Verify Firefox is running with debugging enabled
ps aux | grep firefox.*6000
# Or explicitly launch with port
firefox --remote-debugging-port 6000 &

Port Already in Use

Solution: Use custom port

bash
firefox --remote-debugging-port 7000 &
# Then connect to localhost:7000

Debugger Not Responding

Solution: Ensure prerequisites are met

bash
# Check about:config settings
about:config → devtools.debugger.remote-enabled = true
# Restart Firefox and reconnect

Authentication/Origin Errors

Solution: Configure CORS for RDP

javascript
client.setOriginHeader('http://localhost:3000');

Examples

Full Debugging Session

javascript
const { RDPClient } = require('firefox-rdp');

async function debugFirefox() {
  const client = new RDPClient({ host: 'localhost', port: 6000 });
  
  try {
    await client.connect();
    const tabs = await client.listTabs();
    const tab = tabs[0];
    
    const inspector = await tab.getActor('inspector');
    const console = await tab.getActor('console');
    
    // Inspect element
    const body = await inspector.querySelector('body');
    console.log('Body classes:', await body.getAttributes());
    
    // Execute console command
    const result = await console.evaluateJS('document.title');
    console.log('Page title:', result.value);
    
  } finally {
    await client.disconnect();
  }
}

debugFirefox().catch(console.error);

Integration with Build Tools

javascript
// webpack.config.js
module.exports = {
  devServer: {
    before(app) {
      app.use((req, res, next) => {
        res.setHeader('X-Debugger-Enabled', 'true');
        next();
      });
    }
  },
  // Connect to Firefox RDP for debugging
  devtool: 'eval-source-map'
};

Performance Considerations

  1. RDP Overhead: Remote debugging adds minimal overhead but disable in production
  2. Port Binding: Use high-numbered ports (>6000) to avoid conflicts
  3. Connection Pooling: Reuse RDP connections across multiple operations
  4. Memory: Firefox with debugging enabled uses ~10-15% more memory

Security Notes

  • Local Development Only: Only enable RDP on localhost in development
  • Network Isolation: Don't expose RDP port to untrusted networks
  • Session Management: Disconnect clients when finished
  • Credential Storage: Never log debugging credentials

References

Related Skills

  • files/devtools/chrome-devtools-mcporter - Chrome equivalent
  • superpowers/systematic-debugging - General debugging methodology
  • experts/quality-security/debugger - Debugging expert guidance
  • superpowers/frontend-developer - Frontend development context

Skill Metadata

  • Category: DevTools Integration
  • Complexity: Intermediate
  • Domain: Browser Debugging, Development Tools
  • Platforms: Linux, macOS, Windows
  • Languages: JavaScript, TypeScript, Python (via RDP client)
  • Last Updated: 2025-12-14

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Firefox Devtools」では何ができますか?

Enables Firefox remote debugging workflows, when browser automation or protocol-level Firefox inspection is needed, resulting in configured Firefox RDP access and repeatable debugging steps.

TypingMindでFirefox Devtoolsを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Firefox Devtoolsはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにFirefox Devtoolsをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/zenobi-us/dotfiles/tree/master/files/devtools/agent/bundles/developer/skills/browsers/firefox-devtoolsを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Firefox Devtoolsを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストが合致したときにこのスキルを読み込めます。

Firefox Devtoolsは何個のAIモデルで使えますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもFirefox Devtoolsを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Firefox Devtools」は無料ですか?

はい。zenobi-usがGitHubでMITライセンスの下で公開しています。支払いが必要なのは、利用したトークンに対する、ご自身が契約するAIプロバイダーへの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇