Skip to content
This repository contains compatibility data for Web technologies as displayed on MDN
Branch: master
Clone or download
nmeyvis and ddbeck notification.onclick is working in Firefox (#4079)
* notification.onclick is working in Firefox

* Update api/Notification.json

Co-Authored-By: Daniel D. Beck <daniel@ddbeck.com>
Latest commit 23723e5 May 13, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github chore: Fix CODEOWNERS (#3933) Apr 26, 2019
.vscode Add a VS Code snippet config for creating new BCD files. (#2939) Oct 29, 2018
api notification.onclick is working in Firefox (#4079) May 13, 2019
browsers Add engines to browsers (#3877) May 6, 2019
css Fix Firefox flex property data (#3922) May 13, 2019
html Sort features alphabetically in html/* (#4130) May 10, 2019
http Note that CORP is broken in Chrome 73-74 (#4088) May 10, 2019
javascript Add Node.js version for Object.fromEntries (#4140) May 12, 2019
mathml/elements Add lspace, width, height to mathml.elements.mpadded (#4070) May 13, 2019
schemas Add engines to browsers (#3877) May 6, 2019
scripts Add traverse script (#4120) May 13, 2019
svg Sort features alphabetically in svg/* (#4126) May 10, 2019
test Refactor test-versions.js (#4098) May 10, 2019
webdriver/commands Update Chrome support as most commands are now mostly supported. (#3325) Feb 1, 2019
webextensions Add data for toolbar_field_highlight[_text] (#4139) May 13, 2019
xpath/axes Mirror Chrome -> Webview for xpath/* (#3837) Apr 26, 2019
xslt/elements Add chrome_android release data and correct invalid versions (#1356) Aug 29, 2018
.editorconfig Add .editorconfig file and fix files (#188) May 16, 2017
.gitattributes Avoid line ending inconsistencies (#3231) Jan 7, 2019
.gitignore gitignore: ignore log files (#2216) Jul 13, 2018
.npmignore Add VisualStudio Code extension recommendations and basic settings (#… Aug 9, 2018
.travis.yml Add npm as a deployment provider to travis Oct 30, 2017
CODE_OF_CONDUCT.md Update CoC according to new Mozilla template (#3708) Apr 9, 2019
CONTRIBUTING.md Update package publishing line to reflect governance doc (#3928) Apr 18, 2019
LICENSE Add CC0 license (#175) May 6, 2017
README.md Add link to governance doc from readme (#3798) Apr 10, 2019
USING-CONFLUENCE.md Add note about false positives in Chrome 43 (#3279) Jan 11, 2019
governance.md Add initial CODEOWNERS (#3800) Apr 15, 2019
index.d.ts feat(infra): Split the TypeScript type declaration (#3004) Mar 7, 2019
index.js Make the linter print better error messages (#2338) Jan 7, 2019
package-lock.json 79th alpha version May 9, 2019
package.json Add traverse script (#4120) May 13, 2019
types.d.ts Add engines to browsers (#3877) May 6, 2019

README.md

mdn-browser-compat-data

https://github.com/mdn/browser-compat-data

This repository contains compatibility data for Web technologies. Browser compatibility data describes which platforms (where "platforms" are usually, but not always, web browsers) support particular Web APIs.

This data can be used in documentation, to build compatibility tables listing browser support for APIs. For example: Browser support for WebExtension APIs.

npm Build Status Twitter Follow

Read how this project is governed.

Installation

You can install mdn-browser-compat-data as a node package.

npm install mdn-browser-compat-data

Usage

const bcd = require('mdn-browser-compat-data');
bcd.css.properties.background;
// returns a compat data object (see schema)

Repository contents

There's a top-level directory for each broad area covered: for example, "http", "javascript", "webextensions". Inside each of these directories is one or more JSON file containing the compatibility data.

Please note that we have not (yet) migrated all compatibility data from the MDN wiki pages into this repository.

  • api/ contains data for each Web API interface.

  • css/ contains data for CSS properties, selectors, and at-rules.

  • html/ contains data for HTML elements, attributes, and global attributes.

  • http/ contains data for HTTP headers, statuses, and methods.

  • javascript/ contains data for JavaScript built-in Objects, statement, operators, and other ECMAScript language features.

  • mathml/ contains data for MathML elements, attributes, and global attributes.

  • svg/ contains data for SVG elements, attributes, and global attributes.

  • webdriver/ contains data for WebDriver commands.

  • webextensions/ contains data for WebExtensions JavaScript APIs and manifest keys.

  • xpath/ contains data for XPath axes, and functions.

  • xslt/ contains data for XSLT elements, attributes, and global attributes.

Format of the browser compat json files

The definitive description of the format used to represent compatibility data is the schema file. You can also have a look at the schema documentation.

Please note that we do not (yet) guarantee the stability of the data format. You're welcome to use the data, but its structure is subject to change without notice.

Issues?

If you find a problem, please file a bug.

Contributing

We're very happy to accept contributions to this data. Please familiarize yourself with the schema and send us a pull request. See also the Contributing file for more information.

Browser compatibility tables on MDN

It takes 1-2 weeks for changes in this data to be reflected in MDN's browser compatibility tables. The process is:

  1. A pull request is reviewed and merged to master.
  2. A new release of mdn-browser-compat-data is created by MDN staff. This happens every 4-14 days.
  3. A new image of Kumascript, which includes the BCD release, is built and deployed to production. This happens within a day of the npm package release.
  4. The MDN page using the data is regenerated. For newly converted pages, a staff member switches to the {{Compat}} macro, and re-checks the conversion. For updates to converted pages, a logged-in MDN user force-refreshes the page to regenerate it.

Projects using the data

Here are some projects using the data, as an npm module or directly:

  • Add-ons Linter - the Add-ons Linter is used on addons.mozilla.org and the web-ext tool. It uses browser-compat-data to check that the Firefox version that the add-on lists support for does in fact support the APIs used by the add-on.
  • Browser Compatibility Data Explorer - View, search, and visualize data from the compatibility dataset.
  • Compat Report - Firefox Add-on that shows compatibility data for the current site in the developer tools.
  • compat-tester - Scan local documents for compatibility issues.
  • Visual Studio Code - Shows the compatibility information in the code completion popup.
  • webhint.io - Hints to check if your CSS HTML and JavaScript have deprecated or not broadly supported features.
  • WebStorm - JavaScript IDE allowing you to check whether all CSS properties you use are supported in the target browser version.
You can’t perform that action at this time.