Gathering detailed insights and metrics for chromium-edge-launcher
Gathering detailed insights and metrics for chromium-edge-launcher
Gathering detailed insights and metrics for chromium-edge-launcher
Gathering detailed insights and metrics for chromium-edge-launcher
@rnx-kit/chromium-edge-launcher
EXPERIMENTAL - USE WITH CAUTION - Launch latest Edge with the Devtools Protocol port open
@chiragrupani/karma-chromium-edge-launcher
A Karma plugin. Launcher for different Chromium Edge channels - Dev, Canary, Beta and Stable
karma-chrome-launcher
A Karma plugin. Launcher for Chrome and Chrome Canary.
karma-edge-launcher
A Karma plugin. Launcher for Microsoft Edge.
Launch Microsoft Edge with ease from Node.js.
npm install chromium-edge-launcher
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
7 Stars
230 Commits
1 Forks
4 Watching
6 Branches
49 Contributors
Updated on 18 Jun 2024
Minified
Minified + Gzipped
TypeScript (93.65%)
JavaScript (5.21%)
Shell (1.14%)
Cumulative downloads
Total Downloads
Last day
-4.2%
211,037
Compared to previous day
Last week
3.8%
1,137,020
Compared to previous week
Last month
21.2%
4,405,139
Compared to previous month
Last year
20,211.7%
30,565,860
Compared to previous year
Launch Microsoft Edge with ease from Node.js.
remote-debugging-port
on an available port.kill()
.Ctrl-C
(by default) to terminate the Edge process.1yarn add chromium-edge-launcher 2 3# or with npm: 4npm install chromium-edge-launcher
.launch([opts])
1{ 2 // (optional) remote debugging port number to use. 3 // If provided port is already busy, launch() will reject. 4 // Default: an available port is autoselected 5 port: number; 6 7 // (optional) Additional flags to pass to Edge, 8 // for example: ['--headless', '--disable-gpu']. 9 // See: https://github.com/cezaraugusto/chromium-edge-launcher/blob/main/docs/edge-flags-for-tools.md 10 // Do note, many flags are set by default. 11 // See https://github.com/cezaraugusto/chromium-edge-launcher/blob/master/src/flags.ts 12 edgeFlags: Array<string>; 13 14 // (optional) Close the Edge process on `Ctrl-C`. 15 // Default: true 16 handleSIGINT: boolean; 17 18 // (optional) Explicit path of intended Edge binary. 19 Â // * If this `edgePath` option is defined, it will be used. 20 // * Otherwise, the `EDGE_PATH` env variable will be used if set. 21 // (`LIGHTHOUSE_CHROMIUM_PATH` is deprecated) 22 Â // * Otherwise, a detected Edge Canary will be used if found. 23 // * Otherwise, a detected Edge (stable) will be used. 24 edgePath: string; 25 26 // (optional) Edge profile path to use, if set to `false` then 27 // the default profile will be used. 28 // Default: a fresh Edge profile. 29 userDataDir: string | boolean; 30 31 // (optional) Starting URL to open the browser with 32 // Default: `about:blank` 33 startingUrl: string; 34 35 // (optional) Logging level 36 // Default: 'silent' 37 logLevel: 'verbose'|'info'|'error'|'silent'; 38 39 // (optional) Flags specific in [flags.ts](src/flags.ts) will 40 // not be included. Typically used with the defaultFlags() method 41 // and edgeFlags option. 42 // Default: false 43 ignoreDefaultFlags: boolean; 44 45 // (optional) Interval in ms, which defines how often launcher checks 46 // browser port to be ready. 47 // Default: 500 48 connectionPollInterval: number; 49 50 // (optional) A number of retries, before browser launch 51 // considered unsuccessful. 52 // Default: 50 53 maxConnectionRetries: number; 54 55 // (optional) A dict of environmental key value pairs to pass to 56 // the spawned edge process. 57 envVars: {[key: string]: string}; 58};
.launch().then(edge => ...
1// The remote debugging port exposed by the launched edge 2edge.port: number; 3 4// Method to kill Edge (and cleanup the profile folder) 5edge.kill: () => Promise<void>; 6 7// The process id 8edge.pid: number; 9 10// The childProcess object for the launched Edge 11edge.process: childProcess
EdgeLauncher.Launcher.defaultFlags()
Returns an Array<string>
of the default flags Edge is launched with. Typically used along with the ignoreDefaultFlags
and edgeFlags
options.
Note: This array will exclude the following flags: --remote-debugging-port
--disable-setuid-sandbox
--user-data-dir
.
EdgeLauncher.Launcher.getInstallations()
Returns an Array<string>
of paths to available Edge installations. When edgePath
is not provided to .launch()
, the first installation returned from this method is used instead.
Note: This method performs synchronous I/O operations.
.killAll()
Attempts to kill all Edge instances created with .launch([opts])
. Returns a Promise that resolves to an array of errors that occurred while killing instances. If all instances were killed successfully, the array will be empty.
1const EdgeLauncher = require('chromium-edge-launcher'); 2 3async function cleanup() { 4 await EdgeLauncher.killAll(); 5}
1const EdgeLauncher = require('chromium-edge-launcher'); 2 3EdgeLauncher.launch({ 4 startingUrl: 'https://google.com' 5}).then(edge => { 6 console.log(`Edge debugging port running on ${edge.port}`); 7});
1const EdgeLauncher = require('chromium-edge-launcher'); 2 3EdgeLauncher.launch({ 4 startingUrl: 'https://google.com', 5 edgeFlags: ['--headless', '--disable-gpu'] 6}).then(edge => { 7 console.log(`Edge debugging port running on ${edge.port}`); 8});
1const EdgeLauncher = require('chromium-edge-launcher'); 2 3const newFlags = EdgeLauncher.Launcher.defaultFlags().filter(flag => flag !== '--disable-extensions' && flag !== '--mute-audio'); 4 5EdgeLauncher.launch({ 6 ignoreDefaultFlags: true, 7 edgeFlags: newFlags, 8}).then(edge => { ... });
In a CI environment like Travis, Edge may not be installed. If you want to use chromium-edge-launcher
, Travis can install Edge at run time with an addon. Alternatively, you can also install Edge using the download-edge.sh
script.
Then in .travis.yml
, use it like so:
1language: node_js 2install: 3 - yarn install 4before_script: 5 - export DISPLAY=:99.0 6 - export CHROME_PATH="$(pwd)/edge-linux/edge" 7 - sh -e /etc/init.d/xvfb start 8 - sleep 3 # wait for xvfb to boot 9 10addons: 11 edge: stable
This project started as a fork of Chrome Launcher, which is released under the Apache-2.0 License, and is copyright of Google Inc. Original contributors and git commit history kept intact for proper attribution.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no dangerous workflow patterns detected
Reason
license file detected
Details
Reason
1 existing vulnerabilities detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
Found 1/29 approved changesets -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
security policy file not detected
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2024-11-25
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More