New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

webext-content-scripts

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webext-content-scripts - npm Package Compare versions

Comparing version 0.10.1 to 0.11.0

2

index.d.ts

@@ -6,4 +6,4 @@ import type { Manifest } from 'webextension-polyfill';

}
export declare function executeFunction<Fn extends (...args: any[]) => unknown>(target: number | Target, function_: string | Fn, ...args: unknown[]): Promise<ReturnType<Fn>>;
export declare function executeFunction<Fn extends (...args: any[]) => unknown>(target: number | Target, function_: Fn, ...args: unknown[]): Promise<ReturnType<Fn>>;
export declare function injectContentScript(target: number | Target, scripts: Manifest.ContentScript | Manifest.ContentScript[]): Promise<void>;
export {};

@@ -13,2 +13,13 @@ import chromeP from 'webext-polyfill-kinda';

};
if ('scripting' in chrome) {
const [result] = await chrome.scripting.executeScript({
target: {
tabId,
frameIds: [frameId],
},
func: function_,
args,
});
return result;
}
const [result] = await chromeP.tabs.executeScript(tabId, {

@@ -15,0 +26,0 @@ code: `(${function_.toString()})(...${JSON.stringify(args)})`,

{
"name": "webext-content-scripts",
"version": "0.10.1",
"version": "0.11.0",
"description": "Utility functions to inject content scripts from a WebExtension.",

@@ -42,2 +42,3 @@ "keywords": [

"@sindresorhus/tsconfig": "^2.0.0",
"@types/chrome": "^0.0.170",
"@types/webextension-polyfill": "^0.8.1",

@@ -44,0 +45,0 @@ "typescript": "^4.4.4",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc