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

@browserless/devices

v10.11.3

Published

Comprehensive device database for browser testing. Emulate mobile phones, tablets, and desktops with accurate viewport and user agent data.

Downloads

8,324

Readme

@browserless/devices: A collection of different devices for emulation purposes.

See devices section our website for more information.

Install

Using npm:

npm install @browserless/devices --save

About

This package provides a device descriptor library for browser emulation. It extends Puppeteer's built-in device list with additional desktop devices and provides fuzzy matching capabilities for device name resolution.

What this package does

The @browserless/devices package allows you to:

  • Emulate devices by retrieving viewport dimensions, user agent strings, and device capabilities
  • Use fuzzy matching to resolve device names even with typos or case variations
  • Access extended device list that includes desktop devices missing from Puppeteer's defaults

Device properties

Each device descriptor includes:

| Property | Description | |----------|-------------| | userAgent | Browser user agent string | | viewport.width | Screen width in pixels | | viewport.height | Screen height in pixels | | viewport.deviceScaleFactor | Device pixel ratio (DPR) | | viewport.isMobile | Whether it's a mobile device | | viewport.hasTouch | Whether the device has touch support | | viewport.isLandscape | Whether the device is in landscape mode |

Custom Devices

This package extends Puppeteer's KnownDevices with additional desktop devices:

| Device | Resolution | Scale | |--------|------------|-------| | Macbook Pro 13 | 1280 × 800 | 2x | | Macbook Pro 15 | 1440 × 900 | 2x | | Macbook Pro 16 | 1536 × 960 | 2x | | iMac 21 | 1980 × 1080 | 1x | | iMac 21 4K | 2048 × 1152 | 2x | | iMac 24 4.5K | 4480 × 2520 | 1x | | iMac 27 | 2560 × 1440 | 1x | | iMac 27 5K | 2560 × 1440 | 2x |

Fuzzy Device Name Matching

When lossyDeviceName is enabled (default), the package uses fuzzy matching to resolve device names:

const createGetDevice = require('@browserless/devices')
const getDevice = createGetDevice({ lossyDeviceName: true })

// All of these resolve to "Macbook Pro 13"
getDevice({ device: 'Macbook Pro 13' })
getDevice({ device: 'macbook pro 13' })
getDevice({ device: 'MACBOOK PRO 13' })
getDevice({ device: 'macbook pro' })
getDevice({ device: 'macboo pro' })  // typo still works!

Usage

const createGetDevice = require('@browserless/devices')
const getDevice = createGetDevice()

// Get device by name
const device = getDevice({ device: 'iPhone 13' })
// => { userAgent: '...', viewport: { width: 390, height: 844, ... } }

// Override viewport properties
const customDevice = getDevice({
  device: 'iPad',
  viewport: { isLandscape: true }
})

// Use custom headers
const withHeaders = getDevice({
  headers: { 'user-agent': 'googlebot' }
})

// Access all available devices
console.log(getDevice.deviceDescriptors)

How it fits in the monorepo

This is a standalone utility package with no dependencies on other @browserless/* packages. It's used by:

| Consumer | Purpose | |----------|---------| | @browserless/goto | Sets viewport and user agent when navigating to URLs | | browserless (core) | Exposes getDevice() method on browser contexts |

Dependencies

| Package | Purpose | |---------|---------| | didyoumean3 | Fuzzy string matching for lossy device name resolution | | memoize-one | Caches device lookups for performance | | require-one-of | Auto-detects puppeteer/puppeteer-core installation |

License

@browserless/devices © Microlink, released under the MIT License. Authored and maintained by Microlink with help from contributors.

The logo has been designed by xinh studio.

microlink.io · GitHub microlinkhq · X @microlinkhq