npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@ndiinginc/chrome-path

v1.0.0

Published

Cari lokasi executable Google Chrome (atau varian Chromium) secara otomatis di Windows, macOS, dan Linux.

Readme

@ndiinginc/chrome-path

Cari lokasi executable Google Chrome (atau varian Chromium) secara otomatis di Windows, macOS, dan Linux.

Instalasi

npm install @ndiinginc/chrome-path

Penggunaan

const chromePath = require("@ndiinginc/chrome-path");

const path = chromePath();

if (path) {
    console.log("Chrome ditemukan di:", path);
} else {
    console.log("Chrome tidak ditemukan.");
}

Cara Kerja

Fungsi chromePath() mendeteksi platform yang sedang berjalan (win32, darwin, atau linux) lalu mencari executable di lokasi instalasi umum untuk masing-masing OS. Jika ditemukan, path lengkap dikembalikan sebagai string. Jika tidak ada yang cocok, fungsi mengembalikan null.

Windows

Mencari di beberapa direktori dasar (%LOCALAPPDATA%, %ProgramFiles%, %ProgramFiles(x86)%) dikombinasikan dengan path berikut:

  • Google Chrome
  • Google Chrome Beta
  • Google Chrome Dev
  • Google Chrome SxS (Canary)
  • Google Chrome for Testing
  • Chromium

macOS

Mencari di /Applications dan ~/Applications untuk:

  • Google Chrome
  • Google Chrome Beta
  • Google Chrome Dev
  • Google Chrome Canary
  • Google Chrome for Testing
  • Chromium

Linux

Mencari di path binary umum, termasuk:

  • /usr/bin/google-chrome (dan varian stable/beta/unstable)
  • /usr/bin/chromium / /usr/bin/chromium-browser
  • Snap: /snap/bin/chromium, /snap/bin/google-chrome
  • Flatpak: /var/lib/flatpak/exports/bin/com.google.Chrome

API

chromePath(): string | null

Mengembalikan path absolut ke executable Chrome/Chromium pertama yang ditemukan, atau null jika tidak ada yang ditemukan di sistem.

Requirement

  • Node.js dengan module bawaan fs, path, os (tidak ada dependency eksternal).

Lisensi

MIT