Skip to content

armgit / mimik

Public Imported from GitHub
0

🎬 A browser extension and desktop app that turns your clicks into step-by-step guides with annotated screenshots πŸ“–

340 B
Raw Blame
import type { PublicPath } from 'wxt/browser';
import { browser } from '#imports';

type ScriptPath = Extract<PublicPath, `${string}.js`>;

export function executeScript(tabId: number, files: ScriptPath[], allFrames = true): Promise<unknown> {
  return browser.scripting.executeScript({
    target: { tabId, allFrames },
    files,
  });
}