Files
claude-artifact-scraper/background.js
2025-07-11 10:01:18 -04:00

16 lines
418 B
JavaScript

// Background script for Firefox extension
browser.browserAction.onClicked.addListener((tab) => {
console.log('Extension clicked');
// Check if we're on the correct domain and path
if (!tab.url.startsWith('https://claude.ai/chat/')) {
console.log('Not on claude.ai chat page');
return;
}
// Inject the content script file
browser.tabs.executeScript(tab.id, {
file: 'content.js'
});
});