UNPKG

webext-inject-on-install

Version:

Automatically add content scripts to existing tabs when your extension is installed

100 lines (99 loc) 2.63 kB
{ "name": "webext-inject-on-install", "version": "2.3.0", "description": "Automatically add content scripts to existing tabs when your extension is installed", "keywords": [ "browser", "content script", "existing tabs", "extension", "chrome", "firefox", "safari", "inject" ], "repository": "fregante/webext-inject-on-install", "funding": "https://github.com/sponsors/fregante", "license": "MIT", "author": "Federico Brigante <me@fregante.com> (https://fregante.com)", "type": "module", "exports": { ".": "./distribution/register.js", "./register": "./distribution/register.js", "./inject.js": "./distribution/inject.js" }, "files": [ "distribution" ], "scripts": { "build": "tsc", "demo:build": "parcel build --no-cache", "demo:watch": "parcel watch --no-cache --no-hmr", "prepack": "tsc --sourceMap false", "test": "tsc --noEmit && xo && npm run test:vitest", "test:vitest": "vitest test --preload ./source/test-setup.js", "watch": "tsc --watch" }, "xo": { "rules": { "unicorn/prefer-top-level-await": "off", "@typescript-eslint/no-unsafe-assignment": "off", "@typescript-eslint/no-unsafe-call": "off", "@typescript-eslint/no-unsafe-argument": "off", "type rules disabled because xo is unable to pick up the types": "off" } }, "dependencies": { "webext-content-scripts": "^2.7.2", "webext-detect": "^5.3.2", "webext-events": "^3.1.1", "webext-polyfill-kinda": "^1.0.2" }, "devDependencies": { "@parcel/config-webextension": "^2.14.4", "@sindresorhus/tsconfig": "^7.0.0", "@types/chrome": "^0.0.318", "@types/sinon-chrome": "^2.2.15", "parcel": "^2.14.4", "sinon-chrome": "^3.0.1", "typescript": "^5.8.3", "vitest": "^3.1.2", "xo": "^0.60.0" }, "engines": { "node": ">=18" }, "targets": { "main": false, "default": { "engines": { "browsers": "" }, "source": "./demo/manifest.json", "distDir": "./node_modules/.built/demo", "sourceMap": { "inline": true }, "optimize": false } }, "webExt": { "sourceDir": "node_modules/.built/demo", "run": { "startUrl": [ "https://ephiframe.vercel.app/tab-1", "https://ephiframe.vercel.app/tab-2", "https://ephiframe.vercel.app/tab-3", "https://ephiframe.vercel.app/tab-4", "https://ephiframe.vercel.app/tab-5", "https://ephiframe.vercel.app/tab-6", "https://ephiframe.vercel.app/tab-7", "https://ephiframe.vercel.app/tab-8", "https://ephiframe.vercel.app/tab-9", "https://ephiframe.vercel.app/tab-10", "https://ephiframe.vercel.app/tab-11", "https://alt-ephiframe.vercel.app" ] } } }