Gathering detailed insights and metrics for @brainsights/opn
Gathering detailed insights and metrics for @brainsights/opn
Gathering detailed insights and metrics for @brainsights/opn
Gathering detailed insights and metrics for @brainsights/opn
Open stuff like URLs, files, executables. Cross-platform.
npm install @brainsights/opn
Typescript
Module System
Min. Node Version
Node Version
NPM Version
67.5
Supply Chain
94.3
Quality
74.8
Maintenance
100
Vulnerability
100
License
JavaScript (96.34%)
TypeScript (3.66%)
Total Downloads
3,863
Last Day
1
Last Week
5
Last Month
13
Last Year
102
MIT License
3,295 Stars
203 Commits
253 Forks
29 Watchers
1 Branches
56 Contributors
Updated on Jun 27, 2025
Minified
Minified + Gzipped
Latest Version
5.4.0
Package Id
@brainsights/opn@5.4.0
Unpacked Size
5.92 kB
Size
2.88 kB
File Count
4
NPM Version
6.6.0
Node Version
8.14.0
Cumulative downloads
Total Downloads
Last Day
-50%
1
Compared to previous day
Last Week
0%
5
Compared to previous week
Last Month
-38.1%
13
Compared to previous month
Last Year
3%
102
Compared to previous year
A better node-open. Opens stuff like websites, files, executables. Cross-platform.
spawn
instead of exec
node-open
issuesxdg-open
script for Linux$ npm install opn
1const opn = require('opn'); 2 3// Opens the image in the default image viewer 4opn('unicorn.png').then(() => { 5 // image viewer closed 6}); 7 8// Opens the url in the default browser 9opn('http://sindresorhus.com'); 10 11// Specify the app to open in 12opn('http://sindresorhus.com', {app: 'firefox'}); 13 14// Specify app arguments 15opn('http://sindresorhus.com', {app: ['google chrome', '--incognito']});
Uses the command open
on macOS, start
on Windows and xdg-open
on other platforms.
Returns a promise for the spawned child process. You would normally not need to use this for anything, but it can be useful if you'd like to attach custom event listeners or perform other operations directly on the spawned process.
Type: string
The thing you want to open. Can be a URL, file, or executable.
Opens in the default app for the file type. For example, URLs opens in your default browser.
Type: Object
Type: boolean
Default: true
Wait for the opened app to exit before fulfilling the promise. If false
it's fulfilled immediately when opening the app.
On Windows you have to explicitly specify an app for it to be able to wait.
Type: string
Array
Specify the app to open the target
with, or an array with the app and app arguments.
The app name is platform dependent. Don't hard code it in reusable modules. For example, Chrome is google chrome
on macOS, google-chrome
on Linux and chrome
on Windows.
MIT © Sindre Sorhus
No vulnerabilities found.
Reason
security policy file detected
Details
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
5 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 4
Reason
Found 10/30 approved changesets -- score normalized to 3
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
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
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-06-23
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