Skip to content

Commit

Permalink
[manifest] 특정 페이지에서만 api 작동
Browse files Browse the repository at this point in the history
  • Loading branch information
myeunee committed Oct 16, 2024
1 parent eb55353 commit 83655c5
Showing 1 changed file with 46 additions and 30 deletions.
76 changes: 46 additions & 30 deletions chrome_extension/manifest.json
Original file line number Diff line number Diff line change
@@ -1,34 +1,50 @@
{
"manifest_version": 3,
"name": "PatTurning",
"description": "Extension for Dark Pattern Detection",
"version": "1.3",
"permissions": ["activeTab", "storage", "tabs"],
"host_permissions": [
"YOUR_DARK_PATTERN_API",
"YOUR_PRICE_API",
"*://*/*"
],
"content_security_policy": {
"extension_pages": "default-src 'self'; connect-src YOUR_PRICE_API"
},
"background": {
"service_worker": "scripts/background.js"
},
"content_scripts": [
"manifest_version": 3,
"name": "PatTurning",
"description": "Extension for Dark Pattern Detection",
"version": "1.3",
"permissions": ["activeTab", "storage", "tabs"],
"host_permissions": [
"YOUR_DARK_PATTERN_API",
"YOUR_PRICE_API"
],
"content_security_policy": {
"extension_pages": "default-src 'self'; connect-src YOUR_PRICE_API",
"connect-src": [
"'self'",
"YOUR_DARK_PATTERN_API",
"YOUR_PRICE_API"
]
},
"background": {
"service_worker": "scripts/background.js"
},
"content_scripts": [
{
"matches": [
"*://*.temu.com/*",
"*://*.homeplus.co.kr/*",
"*://*.oasis.co.kr/*",
"*://*.danawa.com/*",
"*://*.coupang.com/*"
],
"js": ["scripts/content-script.js"]
}
],
"action": {
"default_popup": "popup/popup.html",
"default_icon": "images/logo3.png"
},
"web_accessible_resources": [
{
"matches": ["<all_urls>"],
"js": ["scripts/content-script.js"]
"resources": ["fonts/*", "scripts/chart.umd.js", "scripts/renderPriceChart.js"],
"matches": [
"*://*.temu.com/*",
"*://*.homeplus.co.kr/*",
"*://*.oasis.co.kr/*",
"*://*.danawa.com/*",
"*://*.coupang.com/*"
]
}
],
"action": {
"default_popup": "popup/popup.html",
"default_icon": "images/logo3.png"
},
"web_accessible_resources": [
{
"resources": ["fonts/*", "scripts/chart.umd.js", "scripts/renderPriceChart.js"],
"matches": ["<all_urls>"]
}
]
]
}

0 comments on commit 83655c5

Please sign in to comment.