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 🙏

© 2024 – Pkg Stats / Ryan Hefner

browser-manifest

v1.0.0

Published

Validate and normalize a browser manifest

Downloads

6,991

Readme

browser-manifest

An informal specification to describe the basic properties of a browser (in the broadest sense) as well as the features it wants and supports. Includes some code for validating and normalizing a manifest.

npm status node Travis JavaScript Style Guide

Specification

Example

manifest = {
  name: 'chrome',
  version: '26',
  platform: 'windows 2012',
  title: 'Sauce Labs Google Chrome 26 on Windows 2012',
  wants: {
    tunnel: true
  },
  supports: {
    headless: false
  }
}

Properties

name

Required, one of browser-names. Must be a non-empty, lowercase string.

version

Optional but recommended. If defined, it must be a non-empty string. Does not have to be fully qualified, as long as the version is unique among a set of browsers with the same properties. May also be a non-numeric prerelease version like "beta" or "dev". Examples:

  • 6
  • 13.2
  • 11.00.18362.1 (IE)
  • 80.0a1 (Firefox Nightly)
  • beta

title

Optional but recommended. A string for display purposes, for humans to identify this browser among others. Examples:

  • Sauce Labs Google Chrome 27 on Mac 10.12
  • Playwright Firefox
  • System ie 11.00.18362.1

wants

An optional object describing (airtap) features that a browser wants, by the following optional properties:

  • tunnel (boolean): browser needs a tunnel to connect to local test server
  • loopback (boolean): browser needs a hostname other than localhost in order to route 127.0.0.1 traffic through a tunnel.

supports

An optional object describing features supported by a browser, by the following optional properties:

  • headless (boolean): browser can be configured to be headless (TBD: is this distinct from a root headless property that would indicate that the browser is always or never headless?)

options

An optional object with arbitrary properties that exists to customize the browser behavior. Define defaults here, to communicate available options. The options property is ignored in airtap-match-browsers.

provider

Name of the browser-provider that provided this manifest. Not necessary to set, handled internally by Airtap 4.

Additional properties

The manifest may contain additional properties not described here, including nested objects. Such properties can be used by whatever tool launches a browser and by airtap-match-browsers for more specific matching.

API

Usage

const bm = require('browser-manifest')

// Validates and normalizes
const manifest = bm({
  name: 'chrome',
  version: '27'
})

// Adds a few defaults
console.log(manifest.wants) // {}
console.log(manifest.supports) // {}
console.log(manifest.options) // {}

Install

With npm do:

npm install browser-manifest

License

MIT © 2020-present Airtap contributors.