Modernizr Documentation

Modernizr is a JavaScript library that detects HTML5 and CSS3 features in the user’s browser.

RAW Doc

File: README.hi.md

[Binary file]


File: README.id.md

Modernizr menguji fitur CSS3 dan HTML5 asli mana yang tersedia di UA saat ini dan membuat hasilnya tersedia untuk Anda dalam dua cara: sebagai properti pada objek Modernizr global, dan sebagai kelas pada elemen <html>. Informasi ini memungkinkan anda untuk meningkatkan halaman Anda secara bertahap dengan tingkat kontrol yang terperinci.

Melanggar Perubahan Dengan v4

  • Menjatuhkan dukungan untuk versi node <= 10, harap tingkatkan ke setidaknya versi 12

  • Tes berikut diganti namanya:

    • class ke es6class agar tetap sejalan dengan es-test lainnya
  • Tes berikut dipindahkan di subdirektori:

    • cookies, indexeddb, indexedblob, quota-management-api, userdata pindahkan ke subdirektori penyimpanan
    • audio
    • battery pindahkan ke subdirektori audio
    • canvas, canvastext pindahkan ke subdirektori canvas
    • customevent, eventlistener, forcetouch, hashchange, pointerevents, proximity pindahkan ke subdirektori event
    • exiforientation pindahkan ke subdirektori gambar
    • capture, fileinput, fileinputdirectory, formatattribute, input, inputnumber-l10n, inputsearchevent, inputtypes, placeholder, requestautocomplete, validation pindahkan ke subdirektori input
    • svg pindahkan ke subdirektori svg
    • webgl pindahkan ke subdirektori webgl
  • Tes berikut yang telah dihapus:

    • touchevents: diskusi
    • unicode: diskusi
    • templatestrings: duplikat dari deteksi es6 stringtemplate
    • contains: duplikat dari deteksi es6 es6string
    • datalistelem: memanipulasi dari Modernizr.input.list

New Asynchronous Event Listeners

Sering kali orang ingin tahu kapan pengujian asynchronous dilakukan sehingga mereka dapat mengizinkan aplikasi mereka untuk bereaksi terhadapnya. Di masa lalu, Anda harus mengandalkan properti menonton atau kelas <html>. Hanya peristiwa pada pengujian asynchronous yang didukung. Tes sinkron harus ditangani secara sinkron untuk meningkatkan kecepatan dan menjaga konsistensi.

API baru terlihat seperti ini:

js
// Listen to a test, give it a callback
Modernizr.on("testname", function (result) {
  if (result) {
    console.log("The test passed!");
  } else {
    console.log("The test failed!");
  }
});

Kami menjamin bahwa kami hanya akan memanggil fungsi Anda sekali (per kali Anda memanggil on). Kami saat ini tidak mengekspos
metode untuk mengekspos fungsionalitas trigger. Sebagai gantinya, jika Anda ingin memiliki kontrol atas pengujian async, gunakan fitur src/addTest, dan pengujian apa pun yang Anda setel akan secara otomatis mengekspos dan memicu fungsionalitas on.

Getting Started

  • Kloning atau unduh repository
  • Install dependensi proyek dengan npm install

Membangun Modernizr

Dari javascript

Modernizr dapat digunakan secara terprogram melalui npm:

js
var modernizr = require("modernizr");

Metode build diekspos untuk menghasilkan build Modernizr kustom. Contoh:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // the build
});

Parameter pertama mengambil objek opsi JSON dan deteksi fitur untuk disertakan. Lihat lib/config-all.json untuk semua opsi yang tersedia.

Parameter kedua adalah fungsi yang dipanggil pada penyelesaian tugas.

Dari command-line

Kami juga menyediakan antarmuka baris perintah untuk membangun modernizr.
Untuk melihat semua opsi yang tersedia, jalankan:

shell
./bin/modernizr

Atau untuk menghasilkan semua yang ada di 'config-all.json', jalankan ini dengan npm:

shell
npm start
//outputs to ./dist/modernizr-build.js

Testing Modernizr

Untuk menjalankan tes menggunakan mocha-headless-chrome di konsol, jalankan:

shell
npm test

Anda juga dapat menjalankan tes di browser pilihan Anda dengan perintah ini:

shell
npm run serve-gh-pages

dan menavigasi ke dua URL ini:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

Code of Conduct

Proyek ini mematuhi Open Code of Conduct.
Dengan berpertisipasi, anda diharapkan untuk menghormati code ini.

License

Lisensi MIT


File: README.ka.md

  • ಈ ಫೈಲ್ ಅನ್ನು ಪೋರ್ಚುಗೀಸ್-BR ನಲ್ಲಿ ಓದಿ here

  • ಈ ಫೈಲ್ ಅನ್ನು ಇಂಡೋನೇಷಿಯನ್ ಭಾಷೆಯಲ್ಲಿ ಓದಿ here

  • ಈ ಫೈಲ್ ಅನ್ನು ಸ್ಪ್ಯಾನಿಷ್ ಭಾಷೆಯಲ್ಲಿ ಓದಿ here

  • ಈ ಫೈಲ್ ಅನ್ನು ಸ್ವೀಡಿಷ್ ಭಾಷೆಯಲ್ಲಿ here

  • ಈ ಫೈಲ್ ಅನ್ನು ತಮಿಳಿನಲ್ಲಿ ಓದಿ here

  • ಈ ಫೈಲ್ ಅನ್ನು ಕನ್ನಡದಲ್ಲಿ ಓದಿ here

  • ಈ ಫೈಲ್ ಅನ್ನು ಹಿಂದಿಯಲ್ಲಿ ಓದಿ here

  • ನಮ್ಮ ವೆಬ್‌ಸೈಟ್ ಹಳೆಯದಾಗಿದೆ ಮತ್ತು ಮುರಿದುಹೋಗಿದೆ, ದಯವಿಟ್ಟು ಅದನ್ನು ಬಳಸಬೇಡಿ (https://modernizr.com) ಬದಲಿಗೆ npm ನಿಂದ ನಿಮ್ಮ modernizr ಆವೃತ್ತಿಯನ್ನು ನಿರ್ಮಿಸಿ.

  • Documentation

  • Integration tests

  • Unit tests

Modernizr ಪ್ರಸ್ತುತ UA ಯಲ್ಲಿ ಲಭ್ಯವಿರುವ ಸ್ಥಳೀಯ CSS3 ಮತ್ತು HTML5 ವೈಶಿಷ್ಟ್ಯಗಳನ್ನು ಪರೀಕ್ಷಿಸುತ್ತದೆ ಮತ್ತು ಫಲಿತಾಂಶಗಳನ್ನು ನಿಮಗೆ ಎರಡು ರೀತಿಯಲ್ಲಿ ಲಭ್ಯವಾಗುವಂತೆ ಮಾಡುತ್ತದೆ: ಜಾಗತಿಕ Modernizr ವಸ್ತುವಿನ ಗುಣಲಕ್ಷಣಗಳಾಗಿ ಮತ್ತು <html> ಅಂಶದ ಮೇಲೆ ವರ್ಗಗಳಾಗಿವೇ . ಅನುಭವದ ಮೇಲೆ ಹರಳಿನ ಮಟ್ಟದ ನಿಯಂತ್ರಣದೊಂದಿಗೆ ನಿಮ್ಮ ಪುಟಗಳನ್ನು ಹಂತಹಂತವಾಗಿ ವರ್ಧಿಸಲು ಈ ಮಾಹಿತಿಯು ನಿಮಗೆ ಅನುಮತಿಸುತ್ತದೆ.

Breaking changes with v4

  • ನೋಡ್ ಆವೃತ್ತಿಗಳಿಗೆ ಬೆಂಬಲವನ್ನು ಕೈಬಿಡಲಾಗಿದೆ <= 10, ದಯವಿಟ್ಟು ಕನಿಷ್ಠ ಆವೃತ್ತಿ 12 ಗೆ ಅಪ್‌ಗ್ರೇಡ್ ಮಾಡಿ

  • ಕೆಳಗಿನ ಪರೀಕ್ಷೆಗಳನ್ನು ಮರುಹೆಸರಿಸಲಾಗಿದೆ:

    • ಉಳಿದ ಈಸ್-ಟೆಸ್ಟ್‌ಗಳಿಗೆ ಅನುಗುಣವಾಗಿರಲು 'ಕ್ಲಾಸ್' ದಿಂದ ಈಸ್ ೬ಕ್ಲಾಸ್
  • ಕೆಳಗಿನ ಪರೀಕ್ಷೆಗಳನ್ನು ಉಪ ಡೈರೆಕ್ಟರಿಗಳಲ್ಲಿ ಸ್ಥಳಾಂತರಿಸಲಾಗಿದೆ:

    • cookies, indexeddb, indexedblob, quota-management-api, userdata ಸ್ಟೋರೇಜ್ ಸಬ್ ಫೋಲ್ಡರ್ ಸೇರಿಸಲಾಗಿದೆ.
    • audio ಆಡಿಯೊ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
    • battery ಬ್ಯಾಟರಿ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
    • canvas, canvastext ಕ್ಯಾನ್ವಾಸ್ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
    • customevent, eventlistener, forcetouch, hashchange, pointerevents, proximity ಇವೆಂಟ್ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
    • exiforientation ಇಮೇಜ್ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
    • capture, fileinput, fileinputdirectory, formatattribute, input, inputnumber-l10n, inputsearchevent, inputtypes, placeholder, requestautocomplete, validation ಇನ್ ಪುಟ್ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
    • svg ಸ್ ವಿಜಿ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
    • webgl ವೆಬ್ ಜಿಲ್ ಸಬ್ ಫೋಲ್ಡರ್ ಗೆ ಸರಿಸಲಾಗಿದೆ
  • ಕೆಳಗಿನ ಪರೀಕ್ಷೆಗಳನ್ನು ತೆಗೆದುಹಾಕಲಾಗಿದೆ:

    • touchevents: discussion
    • unicode: discussion
    • templatestrings: es6 ನ ನಕಲು stringtemplate ಪತ್ತೆ
    • contains: es6 ನ ನಕಲು es6string ಪತ್ತೆ
    • datalistelem: Modernizr.input.list ನ ಡ್ಯೂಪ್

New Asynchronous Event Listeners

ಆಗಾಗ್ಗೆ ಜನರು ಅಸಮಕಾಲಿಕ ಪರೀಕ್ಷೆಯನ್ನು ಮಾಡಿದಾಗ ತಿಳಿದುಕೊಳ್ಳಲು ಬಯಸುತ್ತಾರೆ ಆದ್ದರಿಂದ ಅವರು ತಮ್ಮ ಅಪ್ಲಿಕೇಶನ್‌ಗೆ ಪ್ರತಿಕ್ರಿಯಿಸಲು ಅನುಮತಿಸಬಹುದು.
ಹಿಂದೆ, ನೀವು ಗುಣಲಕ್ಷಣಗಳನ್ನು ಅಥವಾ <html> ಕ್ಲಾಸ್ ಗಳನ್ನೂ ವೀಕ್ಷಿಸಲು ಅವಲಂಬಿಸಬೇಕಾಗಿತ್ತು. ಅಸಿಂಕ್ರೊನಸ್ ಟೆಸ್ಟ್ ಗಳಲ್ಲಿನ ಈವೆಂಟ್‌ಗಳು ಮಾತ್ರ
ಬೆಂಬಲಿಸಿದರು. ವೇಗವನ್ನು ಸುಧಾರಿಸಲು ಮತ್ತು ಸ್ಥಿರತೆಯನ್ನು ಕಾಪಾಡಿಕೊಳ್ಳಲು ಸಿಂಕ್ರೊನಸ್ ಪರೀಕ್ಷೆಗಳನ್ನು ಸಿಂಕ್ರೊನಸ್ ಆಗಿ ನಿರ್ವಹಿಸಬೇಕು.

ಹೊಸ API ಈ ರೀತಿ ಕಾಣುತ್ತದೆ:

js
// Listen to a test, give it a callback
Modernizr.on("testname", function (result) {
  if (result) {
    console.log("The test passed!");
  } else {
    console.log("The test failed!");
  }
});

ನಾವು ನಿಮ್ಮ ಕಾರ್ಯವನ್ನು ಒಮ್ಮೆ ಮಾತ್ರ ಆಹ್ವಾನಿಸುತ್ತೇವೆ ಎಂದು ನಾವು ಖಾತರಿಪಡಿಸುತ್ತೇವೆ (ನೀವು ಆನ್ ಎಂದು ಕರೆಯುವ ಪ್ರತಿ ಬಾರಿ). ನಾವು ಪ್ರಸ್ತುತ ಬಹಿರಂಗಪಡಿಸುತ್ತಿಲ್ಲ
ಟ್ರಿಗರ್' ಕಾರ್ಯವನ್ನು ಬಹಿರಂಗಪಡಿಸುವ ವಿಧಾನ. ಬದಲಿಗೆ, ನೀವು ಅಸಿಂಕ್ ಪರೀಕ್ಷೆಗಳ ಮೇಲೆ ನಿಯಂತ್ರಣವನ್ನು ಹೊಂದಲು ಬಯಸಿದರೆ, ಬಳಸಿ src/addTestವೈಶಿಷ್ಟ್ಯ, ಮತ್ತು ನೀವು ಹೊಂದಿಸುವ ಯಾವುದೇ ಪರೀಕ್ಷೆಯು ಸ್ವಯಂಚಾಲಿತವಾಗಿಆನ್` ಕಾರ್ಯವನ್ನು ಬಹಿರಂಗಪಡಿಸುತ್ತದೆ ಮತ್ತು ಪ್ರಚೋದಿಸುತ್ತದೆ.

Getting Started

  • ರೆಪೊಸಿಟರಿಯನ್ನು ಕ್ಲೋನ್ ಮಾಡಿ ಅಥವಾ ಡೌನ್‌ಲೋಡ್ ಮಾಡಿ
  • npm install ನೊಂದಿಗೆ ಪ್ರಾಜೆಕ್ಟ್ ಅವಲಂಬನೆಗಳನ್ನು ಸ್ಥಾಪಿಸಿ

Building Modernizr

From javascript

Modernizr ಅನ್ನು npm ಮೂಲಕ ಪ್ರೋಗ್ರಾಮಿಕ್ ಆಗಿ ಬಳಸಬಹುದು:

js
var modernizr = require("modernizr");

ಕಸ್ಟಮ್ ಮಾಡರ್ನಿಜರ್ ಬಿಲ್ಡ್‌ಗಳನ್ನು ಉತ್ಪಾದಿಸಲು ಬಿಲ್ಡ್ ವಿಧಾನವನ್ನು ಬಹಿರಂಗಪಡಿಸಲಾಗಿದೆ. ಉದಾಹರಣೆ:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // the build
});

ಮೊದಲ ಪ್ಯಾರಾಮೀಟರ್ JSON ಆಯ್ಕೆಗಳ ಆಬ್ಜೆಕ್ಟ್ ಅನ್ನು ತೆಗೆದುಕೊಳ್ಳುತ್ತದೆ ಮತ್ತು ಸೇರಿಸಲು ವೈಶಿಷ್ಟ್ಯ-ಪತ್ತೆಹಚ್ಚುತ್ತದೆ. ಲಭ್ಯವಿರುವ ಎಲ್ಲಾ ಆಯ್ಕೆಗಳಿಗಾಗಿ lib/config-all.json ನೋಡಿ.

ಎರಡನೇ ಪ್ಯಾರಾಮೀಟರ್ ಕಾರ್ಯವನ್ನು ಪೂರ್ಣಗೊಳಿಸಿದ ಮೇಲೆ ಕಾರ್ಯವನ್ನು ಹೊಂದಿದೆ.

From the command-line

ಮೊವೆರ್ನೈಜ್ರ್ ನಿರ್ಮಿಸಲು ನಾವು ಆಜ್ಞಾ ಸಾಲಿನ ಇಂಟರ್ಫೇಸ್ ಅನ್ನು ಸಹ ಒದಗಿಸುತ್ತೇವೆ.
ಲಭ್ಯವಿರುವ ಎಲ್ಲಾ ಆಯ್ಕೆಗಳನ್ನು ನೋಡಲು ರನ್ ಮಾಡಿ:

shell
./bin/modernizr

Or 'config-all.json' ನಲ್ಲಿ ಎಲ್ಲವನ್ನೂ ಉತ್ಪಾದಿಸಲು ಇದನ್ನು npm ನೊಂದಿಗೆ ರನ್ ಮಾಡಿ:

shell
npm start
//outputs to ./dist/modernizr-build.js

Testing Modernizr

ಕನ್ಸೋಲ್ ರನ್‌ನಲ್ಲಿ ಮೋಚಾ-ಹೆಡ್‌ಲೆಸ್-ಕ್ರೋಮ್ ಬಳಸಿ ಪರೀಕ್ಷೆಗಳನ್ನು ಕಾರ್ಯಗತಗೊಳಿಸಲು:

shell
npm test

ನೀವು ಕೂಡ ಟೆಸ್ಟ್ ಮಾಡ್ಬಹೌದು ಬ್ರೌಸರ್ ನಲ್ಲಿ ಈ ಕಮ್ಮಂಡ್ ದಿಂದ:

shell
npm run serve-gh-pages

ಮತ್ತು ಈ ಎರಡು URL ಗಳಿಗೆ ನ್ಯಾವಿಗೇಟ್ ಮಾಡಲಾಗುತ್ತಿದೆ:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

Code of Conduct

This project adheres to the Open Code of Conduct.
ಭಾಗವಹಿಸುವ ಮೂಲಕ, ನೀವು ಈ ಕೋಡ್ ಅನ್ನು ಗೌರವಿಸುವ ನಿರೀಕ್ಷೆಯಿದೆ.

License

MIT License


File: README.md

Modernizr tests which native CSS3 and HTML5 features are available in the current UA and makes the results available to you in two ways: as properties on a global Modernizr object, and as classes on the <html> element. This information allows you to progressively enhance your pages with a granular level of control over the experience.

Breaking changes with v4

  • Dropped support for node versions <= 10, please upgrade to at least version 12

  • Following tests got renamed:

    • class to es6class to keep in line with the rest of the es-tests
  • Following tests got moved in subdirectories:

    • cookies, indexeddb, indexedblob, quota-management-api, userdata moved into the storage subdirectory
    • audio moved into the audio subdirectory
    • battery moved into the battery subdirectory
    • canvas, canvastext moved into the canvas subdirectory
    • customevent, eventlistener, forcetouch, hashchange, pointerevents, proximity moved into the event subdirectory
    • exiforientation moved into the image subdirectory
    • capture, fileinput, fileinputdirectory, formatattribute, input, inputnumber-l10n, inputsearchevent, inputtypes, placeholder, requestautocomplete, validation moved into the input subdirectory
    • svg moved into the svg subdirectory
    • webgl moved into the webgl subdirectory
  • Following tests got removed:

    • touchevents: discussion
    • unicode: discussion
    • templatestrings: duplicate of the es6 detect stringtemplate
    • contains: duplicate of the es6 detect es6string
    • datalistelem: A dupe of Modernizr.input.list

New Asynchronous Event Listeners

Often times people want to know when an asynchronous test is done so they can allow their application to react to it.
In the past, you've had to rely on watching properties or <html> classes. Only events on asynchronous tests are
supported. Synchronous tests should be handled synchronously to improve speed and to maintain consistency.

The new API looks like this:

js
// Listen to a test, give it a callback
Modernizr.on("testname", function (result) {
  if (result) {
    console.log("The test passed!");
  } else {
    console.log("The test failed!");
  }
});

We guarantee that we'll only invoke your function once (per time that you call on). We are currently not exposing
a method for exposing the trigger functionality. Instead, if you'd like to have control over async tests, use the
src/addTest feature, and any test that you set will automatically expose and trigger the on functionality.

Getting Started

  • Clone or download the repository
  • Install project dependencies with npm install

Building Modernizr

From javascript

Modernizr can be used programmatically via npm:

js
var modernizr = require("modernizr");

A build method is exposed for generating custom Modernizr builds. Example:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // the build
});

The first parameter takes a JSON object of options and feature-detects to include. See lib/config-all.json for all available options.

The second parameter is a function invoked on task completion.

From the command-line

We also provide a command line interface for building modernizr.
To see all available options run:

shell
./bin/modernizr

Or to generate everything in 'config-all.json' run this with npm:

shell
npm start
//outputs to ./dist/modernizr-build.js

Testing Modernizr

To execute the tests using mocha-headless-chrome on the console run:

shell
npm test

You can also run tests in your browser of choice with this command:

shell
npm run serve-gh-pages

and navigate to these two URLs:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

Integrating Modernizr with Build Tools

This section provides guidance on how to integrate Modernizr with various build tools and frameworks, making it easier to use in your projects.

1. Integrating with Webpack

To integrate Modernizr with Webpack, follow these steps:

  1. Install Modernizr:

    bash
    npm install modernizr --save
  2. Create a Modernizr Configuration File:
    Create a file named modernizr-config.js in your project root:

    javascript
    module.exports = {
      "feature-detects": [
        "test/feature1",
        "test/feature2",
        // Add more feature detects as needed
      ]
    };
  3. Update Webpack Configuration:
    Modify your Webpack configuration file (e.g., webpack.config.js) to include the Modernizr plugin:

    javascript
    const ModernizrWebpackPlugin = require('modernizr-webpack-plugin');
    
    module.exports = {
      // Other configurations...
      plugins: [
        new ModernizrWebpackPlugin({
          "feature-detects": [
            "test/feature1",
            "test/feature2"
          ]
        })
      ]
    };
  4. Build Your Project:
    Run your Webpack build process:

    bash
    npm run build

2. Integrating with Gulp

If you are using Gulp, you can integrate Modernizr as follows:

  1. Install Modernizr:

    bash
    npm install modernizr --save-dev
  2. Create a Gulp Task:
    In your gulpfile.js, add a task to build Modernizr:

    javascript
    const gulp = require('gulp');
    const modernizr = require('modernizr');
    
    gulp.task('modernizr', function() {
      return modernizr.build({
        "feature-detects": [
          "test/feature1",
          "test/feature2"
        ]
      }).pipe(gulp.dest('dist/'));
    });
  3. Run the Gulp Task:
    Execute the task to generate the Modernizr build:

    bash
    gulp modernizr

3. Integrating with Parcel

For projects using Parcel, you can integrate Modernizr as follows:

  1. Install Modernizr:

    bash
    npm install modernizr --save
  2. Create a Modernizr Configuration File:
    Similar to the Webpack setup, create a modernizr-config.js file:

    javascript
    module.exports = {
      "feature-detects": [
        "test/feature1",
        "test/feature2"
      ]
    };
  3. Update Parcel Configuration:
    You can use a plugin like parcel-plugin-modernizr to integrate Modernizr:

    bash
    npm install parcel-plugin-modernizr --save-dev
  4. Build Your Project:
    Run Parcel to build your project:

    bash
    parcel build index.html

Conclusion

Integrating Modernizr with your build tools can enhance your web applications by allowing you to detect and respond to the capabilities of the user's browser. Follow the steps above to set up Modernizr with your preferred build tool.

For more information, refer to the Modernizr documentation.

Code of Conduct

This project adheres to the Open Code of Conduct.
By participating, you are expected to honor this code.

License

MIT License


File: README.pt_br.md

Português-BR

Modernizr é uma biblioteca de JavaScript que detecta recursos HTML5 e CSS3 no navegador do usuário.

Modernizr testa quais recursos nativos de HTML5 e CSS3 estão disponíveis na UA atual, e deixa os recursos disponíveis para você em duas maneiras: como propriedades num objeto global Modernizr, e como classes no elemento <html>. Essa informação permite que você melhore progressivamente suas páginas com um nível granular de controle sobre a experiência.

Mudanças com a v4

  • Fechou o suporte para Node 8, por favor atualize para Node v10

  • Esses testes foram removidos:

    • touchevents: discussion
    • unicode: discussion
    • templatestrings: duplicate of the es6 detect stringtemplate
    • contains: duplicate of the es6 detect es6string
    • datalistelem: A dupe of Modernizr.input.list

Novos Event Listeners Assíncronos

Várias vezes as pessoas querem saber quando um teste assíncrono é feito pra que eles possam autorizar suas aplicações a reagir com ele. No passado, tinha que confiar em ficar monitorando propriedades ou em classes <html>. Apenas eventos em testes asynchronous possuem suporte. Testes síncronos devem ser manipulados sincronamente para aumentar velocidade e manter consistência.

A API nova está assim:

js
// Listen to a test, give it a callback
Modernizr.on('testname', function( result ) {
  if (result) {
    console.log('O teste passou!');
  }
  else {
    console.log('O teste falhou!');
  }
});

Nós garantimos que só vamos invocar sua função uma vez (por vezes que você chame on). Atualmente não estamos expondo um método para expôr a funcionalidade trigger. Em vez disso, se você gostaria de ter controle sobre testes assíncronos, use o recurso src/addTest, e qualquer teste que você faça vai automaticamente expôr e ativar a funcionalidade on.

Começando

  • Clone ou baixe o repositório
  • Instale as dependências do projeto com npm install

Construindo Modernizr

Pelo JavaScript

Modernizr pode ser usado programaticamente via npm:

js
var modernizr = require("modernizr");

Um método build é exposto para gerar builds customizadas do Modernizr. Exemplo:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // a build
});

O primeiro parâmetro pega um objeto JSON de opções e detector de recursos para incluir. Veja lib/config-all.json para todas opções disponíveis.

O segundo parâmetro é uma função invocada pela conclusão de tarefa.

Pela linha de comando

Nós também disponibilizamos uma interface na linha de comando para a construção do Modernizr. Para ver todas opções disponíveis digite:

shell
./bin/modernizr

Ou para gerar tudo no 'config-all.json' digite isso com o npm:

shell
npm start
//outputs to ./dist/modernizr-build.js

Testando Modernizr

Para executar os testes usando mocha-headless-chrome no console, use:

shell
npm test

Também tem como fazer testes no navegador de sua escolha com esse comando:

shell
npm run serve-gh-pages

e navegando para essas duas URLs:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

Código de Conduta

Este projeto adere ao Código Aberto de Conduta.
Participando deste projeto, é esperado que você honre esse código.

Licensa

Licensa MIT


File: README.sp.md

Modernizr testea cuales características nativas de CSS3 y HTML5 están disponibles en el actual UA y le devuelve los resultados de dos formas: como propiedades de un objeto global Modernizr, y como clases en el elemento <html>. Esta información le permite mejorar progresivamente sus páginas con un nivel de control granular sobre las experiencias.

Breaking changes with v4

  • Sin soporte para versiones de Node <= 10, por favor actualizar por lo menos a la versión 12

  • Los siguientes tests fueron renombrados:

    • class a es6class para mantenerse en linea con el resto de los es-tests
  • Los siguientes tests fueron movidos a subdirectorios:

    • cookies, indexeddb, indexedblob, quota-management-api, userdata movidos al subdirectorio storage
    • audio movido al subdirectorio audio
    • battery movido al subdirectorio battery
    • canvas, canvastext movidos al subdirectorio canvas
    • customevent, eventlistener, forcetouch, hashchange, pointerevents, proximity movidos al subdirectorio event
    • exiforientation movidos al subdirectorio image
    • capture, fileinput, fileinputdirectory, formatattribute, input, inputnumber-l10n, inputsearchevent, inputtypes, placeholder, requestautocomplete, validation movidos al subdirectorio input
    • svg movido al subdirectorio svg
    • webgl movido al subdirectorio webgl
  • Los siguientes tests fueron removidos:

    • touchevents: discusión
    • unicode: discusión
    • templatestrings: duplicado de la detección es6 stringtemplate
    • contains: duplicado de la detección es6 es6string
    • datalistelem: Una replica de Modernizr.input.list

New Asynchronous Event Listeners

A menudo las personas quieren saber cuando un test asíncrono se ha realizado y de esta forma permitir que la aplicación reaccione a esto.
En el pasado, usted ha tenido que verificar las propiedades o clases de <html>. Solo los enventos en los tests asynchronous están soportados.
Tests síncronos deberían ser manejados sincrónicamente para mejorar la velocidad y mantener la consistencia.

La nueva API se ve así:

js
// Escuchando un test, dar un callback
Modernizr.on('testname', function( result ) {
  if (result) {
    console.log('Test exitoso!');
  }
  else {
    console.log('El test ha fallado!');
  }
});

Garantizamos que solo invocaremos tu función una vez (por cada vez que llames a on). Actualmente no estamos exponiendo
un metodo para exponer la funcionalidad de trigger. En cambio, si quisiera tener el control sobre los tests asíncronos, use la
característica src/addTest, y cualquier test que establezca automáticamente expondrá y encenderá la funcionalidad on.

Getting Started

  • Clone o descargue el repositorio
  • Instale las dependencias del proyecto con npm install

Building Modernizr

From javascript

Modernizr puede ser usado programáticamente via npm:

js
var modernizr = require("modernizr");

Un método build está expuesto para generar builds personalizadas. Ejemplo:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // la build
});

El primer parámetro toma un objeto JSON de opciones y feature-detects a incluir. Ver lib/config-all.json para todas las opciones disponibles.

El segundo parámetro es una función invocada cuando la tarea se ha completado.

From the command-line

También proveemos una CLI para building modernizr.
Para ver todas las opciones disponibles, ejecutar:

shell
./bin/modernizr

O generar todo en 'config-all.json' ejecutar esto con npm:

shell
npm start
//outputs to ./dist/modernizr-build.js

Testing Modernizr

Para ejecutar los tests usando mocha-headless-chrome en la consola, ejecutar:

shell
npm test

También se pueden correr en el navegador de su elección usando:

shell
npm run serve-gh-pages

y navegando a estas dos URLs:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

Code of Conduct

Este proyecto se adhiere al Open Code of Conduct.
Al participar, se espera que honre este código.

License

MIT License


File: README.sv.md

Modernizr testar vilka inbyggda CSS3- och HTML5-funktioner som är tillgängliga i den aktuella UA och gör resultaten tillgängliga för dig på två sätt: som egenskaper på ett globalt Modernizr-objekt och som klasser på <html>-elementet. Denna information gör att du gradvis kan förbättra dina sidor med detaljerad information över upplevelsen.

Förändringar med v4

  • Avbrutet stöd för node versioner <= 10, uppgradera till minst version 12

  • Följande tester har bytt namn:

    • class till es6class för att vara närmare resten av es-testen
  • Följande tester har flyttats till underkataloger:

    • cookies, indexeddb, indexedblob, quota-management-api, userdata flyttade till storage underkatalogen
    • audio flyttade till audio underkatalogen
    • battery flyttade till battery underkatalogen
    • canvas, canvastext flyttade till canvas underkatalogen
    • customevent, eventlistener, forcetouch, hashchange, pointerevents, proximity flyttade till event underkatalogen
    • exiforientation flyttade till image underkatalogen
    • capture, fileinput, fileinputdirectory, formatattribute, input, inputnumber-l10n, inputsearchevent, inputtypes, placeholder, requestautocomplete, validation flyttade till input underkatalogen
    • svg flyttade till svg underkatalogen
    • webgl flyttade till webgl underkatalogen
  • Följande tester har tagits bort:

    • touchevents: diskussion
    • unicode: diskussion
    • templatestrings: dubblett av es6 detect stringtemplate
    • contains: dublett av es6 detect es6string
    • datalistelem: En dublett av Modernizr.input.list

Nya asynkrona händelselyssnare

Folk vill ofta veta när ett asynkront test görs så att de kan låta deras applikation reagera på det.
Tidigare har du varit tvungen att lita på att titta på egenskaper eller <html>-klasser. Tester stöder ändast asynkrona händelser.
Synkrona tester bör hanteras synkront för att förbättra hastigheten och bibehålla konsekvenser.

Det nya API:n ser ut så här:

js
// Listen to a test, give it a callback
Modernizr.on("testname", function (result) {
  if (result) {
    console.log("The test passed!");
  } else {
    console.log("The test failed!");
  }
});

Vi garanterar att vi bara kommer att anropa din funktion en gång (per gång du aktiverar on funktionen). Vi förser för närvarande inte
en metod för att exponera "trigger"-funktionen. Istället, om du vill ha kontroll över dina asynkronatester, använd
src/addTest-funktionen, och varje test som du ställer in kommer automatiskt att exponera och trigga on-funktionen.

Kom igång

  • Klona eller ladda ned arkivet.
  • Installera projektberoenden med npm install

Att bygga Modernizr

Från javascript

Modernizr kan användas via npm:

js
var modernizr = require("modernizr");

En build metod är exponerad för att generera anpassade Modernizr-builds. Exempel:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // the build
});

Den första parametern tar med ett JSON-objekt med alternativ och funktioner. Se lib/config-all.json för alla alternativ.

Den andra parametern är en funktion som anropas när uppgiften är klar.

Från kommandocentralen

Vi tillhandahåller också ett kommando för att bygga modernizr.
För att se alla tillgängliga alternativ körs:

shell
./bin/modernizr

Eller för att generera allt i 'config-all.json' kör detta med npm:

shell
npm start
//outputs to ./dist/modernizr-build.js

Testa Modernizr

Så här kör du testerna med mocha-headless-chrome på konsolen:

shell
npm test

Du kan också köra tester i den webbläsare du väljer med detta kommando:

shell
npm run serve-gh-pages

och navigera till dessa två webbadresser:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

Uppförandekod

Detta projekt följer Open Code of Conduct.
Genom att delta förväntas du respektera detta.

License

MIT License


File: README.ta.md

  • இந்த கோப்பை போர்ச்சுகீஸ் மொழியில் படிக்கவும்-பி.ஆர் இங்கே

  • இந்தக் கோப்பை இந்தோனேசிய மொழியில் படிக்கவும் இங்கே

  • இந்த கோப்பை ஸ்பானிஷ் மொழியில் இங்கே

  • இந்த கோப்பை ஸ்வீடிஷ் மொழியில் படிக்கவும் இங்கே

  • இந்த கோப்பை தமிழில் படிக்கவும் இங்கே

  • இந்த கோப்பை கன்னடத்தில் படிக்கவும் இங்கே

  • இந்த கோப்பை இந்தியில் படிக்கவும் here

  • எங்கள் இணையதளம் காலாவதியானது மற்றும் உடைந்துவிட்டது, தயவுசெய்து அதைப் பயன்படுத்த வேண்டாம் (https://modernizr.com) மாறாக உங்கள் நவீனமயமாக்கல் பதிப்பை npm இலிருந்து உருவாக்கவும்.

  • ஆவணப்படுத்தல்

  • இடையீடு சோதனைகள்

  • அலகு சோதனைகள்

மாடர்னிசர் தற்போதைய யுஏ இல் எந்த சொந்த சிஎஸ்எஸ்3 மற்றும் எச்டிஎம்எல்5 அம்சங்கள் உள்ளன என்பதைச் சோதித்து, முடிவுகளை இரண்டு வழிகளில் உங்களுக்குக் கிடைக்கச் செய்கிறது: உலகளாவிய Modernizr பொருளின் பண்புகளாகவும், <html> உறுப்புக்கான வகுப்புகளாகவும். இந்தத் தகவல், அனுபவத்தின் மீதான சிறு அளவிலான கட்டுப்பாட்டுடன் உங்கள் பக்கங்களை படிப்படியாக மேம்படுத்த அனுமதிக்கிறது.

v4 உடன் மாற்றங்களை உடைக்கிறது

  • முனை பதிப்புகளுக்கான ஆதரவு கைவிடப்பட்டது <= 10, தயவுசெய்து குறைந்தபட்சம் பதிப்பு 12 க்கு மேம்படுத்தவும்

  • பின்வரும் சோதனைகள் மறுபெயரிடப்பட்டன:

    • வகுப்பு முதல் es6class வரை மீதமுள்ள es-சோதனைகளுக்கு ஏற்ப இருக்க வேண்டும்
  • பின்வரும் சோதனைகள் துணை அடைவுகளில் நகர்த்தப்பட்டன:

    • cookies, indexeddb, indexedblob, quota-management-api, userdata சேமிப்பக துணை அடைவுக்கு நகர்த்தப்பட்டது
    • audio ஆடியோ துணை அடைவுக்கு நகர்த்தப்பட்டது
    • battery பேட்டரி துணை அடைவுக்கு நகர்த்தப்பட்டது
    • canvas, canvastext கேன்வாஸ் துணை அடைவுக்கு நகர்த்தப்பட்டது
    • customevent, eventlistener, forcetouch, hashchange, pointerevents, proximity நிகழ்வு துணை அடைவுக்கு நகர்த்தப்பட்டது
    • exiforientation படத்தின் துணை அடைவுக்கு நகர்த்தப்பட்டது
    • capture, fileinput, fileinputdirectory, formatattribute, input, inputnumber-l10n, inputsearchevent, inputtypes, placeholder, requestautocomplete, validation உள்ளீட்டிற்கு நகர்த்தப்பட்டது துணை அடைவு
    • svg எஸ்.வி.ஜி துணை அடைவுக்கு நகர்த்தப்பட்டது
    • webgl wவலைஜிஎல் துணை அடைவுக்கு நகர்த்தப்பட்டது
  • பின்வரும் சோதனைகள் நீக்கப்பட்டன:

    • தொடுதல் நிகழ்வுகள்: விவாதம்
    • யூனிகோட்: விவாதம்
    • வார்ப்புருக்கள்: ஈஎஸ்6 கண்டறிதலின் நகல் stringtemplate
    • கொண்டுள்ளது: ஈஎஸ்6 கண்டறிதலின் நகல் es6string
    • தரவு பட்டியல்: Modernizr.input.list இன் போலி

புதிய ஒத்திசைவற்ற நிகழ்வு கேட்போர்

ஒரு ஒத்திசைவற்ற சோதனை எப்போது செய்யப்படுகிறது என்பதை மக்கள் அடிக்கடி அறிய விரும்புகிறார்கள், அதனால் அவர்கள் தங்கள் விண்ணப்பத்தை அதற்கு எதிர்வினையாற்ற அனுமதிக்கலாம்.
கடந்த காலத்தில், பண்புகள் அல்லது <html> வகுப்புகளைப் பார்ப்பதில் நீங்கள் தங்கியிருக்க வேண்டியிருந்தது. ஒத்திசைவற்ற சோதனைகளில் நிகழ்வுகள் மட்டுமே
ஆதரித்தது. வேகத்தை மேம்படுத்தவும், நிலைத்தன்மையை பராமரிக்கவும் ஒத்திசைவான சோதனைகள் ஒத்திசைவாக கையாப்பட வேண்டும்.

புதிய ஏபிஈ API இது போல் தெரிகிறது

js
// ஒரு சோதனையைக் கேளுங்கள், அதை மீண்டும் அழைக்கவும்
Modernizr.on("testname", function (result) {
  if (result) {
    console.log("The test passed!");
  } else {
    console.log("The test failed!");
  }
});

உங்கள் செயல்பாட்டை ஒருமுறை மட்டுமே செயல்படுத்துவோம் என்று நாங்கள் உத்தரவாதம் அளிக்கிறோம் (ஒரு முறை நீங்கள் ஆன் என்று அழைக்கும் போது). நாங்கள் தற்போது வெளிப்படுத்தவில்லை
தூண்டுதல் செயல்பாட்டை வெளிப்படுத்துவதற்கான ஒரு முறை. அதற்குப் பதிலாக, ஒத்திசைவு சோதனைகளின் மீது நீங்கள் கட்டுப்பாட்டைப் பெற விரும்பினால், இதைப் பயன்படுத்தவும்
src/addTest அம்சம் மற்றும் நீங்கள் அமைக்கும் எந்த சோதனையும் தானாகவே ஆன் செயல்பாட்டை வெளிப்படுத்தும் மற்றும் தூண்டும்.

தொடங்குதல்

  • களஞ்சியத்தை குளோன் செய்யவும் அல்லது பதிவிறக்கவும்
  • npm install மூலம் திட்ட சார்புகளை நிறுவவும்

கட்டிடம் நவீனமயமாக்கல்

ஜாவாஸ்கிரிப்டில் இருந்து

மாடர்னிசர் ஐ npm வழியாக நிரல் ரீதியாகப் பயன்படுத்தலாம்:

js
var modernizr = require("modernizr");

தனிப்பயன் மாடர்னிசர் பில்ட்களை உருவாக்குவதற்கான ஒரு build முறை வெளிப்படுகிறது. உதாரணமாக:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // the build
});

முதல் அளவுருவானது JSON ஆப்ஜெக்ட் ஆப்ஜெக்ட் மற்றும் அம்சத்தைக் கண்டறிகிறது. கிடைக்கக்கூடிய அனைத்து விருப்பங்களுக்கும் lib/config-all.json ஐப் பார்க்கவும்.

இரண்டாவது அளவுரு என்பது பணியை முடிக்கும் போது செயல்படுத்தப்படும் ஒரு செயல்பாடாகும்.

கட்டளை வரியிலிருந்து

நவீனமயமாக்கலை உருவாக்குவதற்கான கட்டளை வரி இடைமுகத்தையும் நாங்கள் வழங்குகிறோம்.
கிடைக்கக்கூடிய அனைத்து விருப்பங்களையும் பார்க்க, இயக்கவும்:

shell
./bin/modernizr

அல்லது 'config-all.json' இல் அனைத்தையும் உருவாக்க, இதை npm உடன் இயக்கவும்:

shell
npm start
//outputs to ./dist/modernizr-build.js

மாடர்னிசர் சோதனை

கன்சோல் இயக்கத்தில் mocha-headless-chrome ஐப் பயன்படுத்தி சோதனைகளைச் செயல்படுத்த:

shell
npm test

இந்தக் கட்டளையைப் பயன்படுத்தி உங்களுக்கு விருப்பமான உலாவியில் சோதனைகளையும் இயக்கலாம்:

shell
npm run serve-gh-pages

மற்றும் இந்த இரண்டு URLகளுக்கு செல்லவும்:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

நடத்தை விதிகள்

இந்த திட்டம் ஓப்பன் கான்டக்ட் கோட் இணங்குகிறது.
பங்கேற்பதன் மூலம், இந்த குறியீட்டை நீங்கள் மதிக்க வேண்டும் என்று எதிர்பார்க்கப்படுகிறது.

உரிமம்

எம்ஐடி உரிமம்


File: README.tr.md

Modernizr, mevcut UA'da hangi yerel CSS3 ve HTML5 özelliklerinin bulunduğunu test eder ve sonuçları size iki şekilde sunar: global bir Modernizr nesnesi üzerinde özellikler olarak ve <html> öğesinde sınıflar olarak. Bu bilgiler, sayfalarınızı deneyim üzerinde ayrıntılı bir kontrolle aşamalı olarak geliştirmenize olanak tanır.

Breaking changes with v4

  • Düğüm sürümleri <= 10 için destek kaldırıldı, lütfen en az sürüm 12'ye yükseltin

  • Aşağıdaki testler yeniden adlandırıldı:

    • es-testlerin geri kalanıyla aynı çizgide kalmak için classtan es6classa
  • Aşağıdaki testler alt dizinlere taşındı:

    • cookies, indexeddb, indexedblob, quota-management-api, userdata storage alt
      dizinine taşındı.
    • audio audio alt dizinine taşındı.
    • battery battery alt dizinine taşındı.
    • canvas, canvastext canvas alt dizinine taşındı.
    • customevent, eventlistener, forcetouch, hashchange, pointerevents, proximity event
      alt dizinine taşındı.
    • exiforientation image alt dizinine taşındı.
    • capture, fileinput, fileinputdirectory, formatattribute, input, inputnumber-l10n, inputsearchevent, inputtypes, placeholder, requestautocomplete, validation input
      alt dizinine taşındı.
    • svg svg alt dizinine taşındı.
    • webglwebgl alt dizinine taşındı.
  • Aşağıdaki testler kaldırıldı:

    • touchevents: discussion
    • unicode: discussion
    • templatestrings: es6'nın kopyası stringtemplatei algılar
    • contains: es6'nın kopyası es6stringi algılar
    • datalistelem: Modernizr.input.list'in kopyası

New Asynchronous Event Listeners

Çoğu zaman insanlar, uygulamalarının buna tepki vermesine izin verebilmek için eşzamansız bir testin ne zaman yapıldığını bilmek isterler.
Geçmişte özellikleri izlemeye veya "" sınıflarına güvenmek zorundaydınız. Yalnızca asynchronous testler desteklenir.
Hızı artırmak ve tutarlılığı korumak için eşzamanlı testler eşzamanlı olarak ele alınmalıdır.

Yeni API şuna benzer:

js
// Listen to a test, give it a callback
Modernizr.on("testname", function (result) {
  if (result) {
    console.log("The test passed!");
  } else {
    console.log("The test failed!");
  }
});

Fonksiyonunuzu yalnızca bir kez çağıracağımızı garanti ederiz (on olarak çağıracağınız her zaman için).
Şu anda trigger işlevselliğini ortaya çıkarmak için bir metod göstermiyoruz.
Bunun yerine, eşzamansız testler üzerinde kontrole sahip olmak istiyorsanız,
src/addTest özelliğini kullanın, ve ayarladığınız herhangi bir test otomatik olarak on fonksiyonunu
ortaya çıkaracak ve tetikleyecektir.

Getting Started

  • Repoyu klonlayın veya indirin
  • Proje bağımlılıklarını npm install ile yükleyin

Building Modernizr

From javascript

Modernizr, npm aracılığıyla programlı olarak kullanılabilir:

js
var modernizr = require("modernizr");

Özel Modernizr yapıları oluşturmak için bir build yöntemi kullanıma sunuldu. Örnek:

javascript
var modernizr = require("modernizr");

modernizr.build({}, function (result) {
  console.log(result); // the build
});

İlk parametre, eklenecek seçeneklerden ve özellik algılamalarından oluşan bir JSON nesnesini alır. Mevcut tüm seçenekler için lib/config-all.json bakın.

İkinci parametre, görev tamamlandığında çağrılan bir fonksiyondur.

From the command-line

Ayrıca modernizr oluşturmak için bir komut satırı arayüzü de sağlıyoruz.
Tüm mevcut seçenekleri görmek için çalıştırın:

shell
./bin/modernizr

Her şeyi 'config-all.json' dosyasında oluşturmak için npm ile şunu çalıştırın:

shell
npm start
//outputs to ./dist/modernizr-build.js

Testing Modernizr

Mocha-headless-chrome kullanarak testleri konsolda çalıştırmak için şunu yazın:

shell
npm test

Bu komutla istediğiniz tarayıcıda da testleri çalıştırabilirsiniz:

shell
npm run serve-gh-pages

Ve bu iki URL'e giderek:

shell
http://localhost:8080/test/unit.html
http://localhost:8080/test/integration.html

Code of Conduct

Bu proje aşağıdaki kurallara uygundur Open Code of Conduct.
Projeye katılmanız durumunda bu kurallara uymanız bekleniyor.

License

MIT License


File: HOW_TO_WRITE_FEATURE_DETECTS.md

How to Write Feature Detects

The scope of this file is to help you to create new feature detects or edit existing ones. Here you will find details and guidelines that will help you understand how Modernizr works. All these sections assume that you have npm, node and Modernizr downloaded. If that is not the case, check first the Install the basics section.

Table of contents

Metadata

Polyfills

Submitting a PR

Testing

Install the Basics

Metadata

A JSON fragment at the top of every feature detect in Modernizr represents the metadata of the test. This data is used, for example, to build the webpage.

Metadata Schema

The following code represents an example of the schema (it does not represent a real test):

json
/*!
{
  "name": "JPEG 2000",
  "property": "jpeg2000",
  "tags": ["media", "image"],
  "caniuse": "jpeg2000",
  "authors": ["Markel Ferro (@MarkelFe)", "@rejas", "Brandom Aaron"],
  "builderAliases": ["jpeg2"],
  "polyfills": ["jpeg2000js"],
  "aliases": ["jpeg-2000", "jpg2"],
  "async": true,
  "warnings": ["These tests currently require document.body to be present"],
  "knownBugs": ["This will false positive in IE6"],
  "notes": [{
    "name": "Specification",
    "href": "https://www.w3.org/"
  }, {
    "name": "Github issue",
    "href": "https://github.com/Modernizr/"
  }]
}
!*/
/* DOC
Here it would go a description of the feature test. You can use **markdown** here :)
*/

Metadata does no need to appear in a set order, however, it is common to see name and property at the top while notes at the bottom.

Metadata Item description

Necessity Description Notes
name required Name of the feature detection
property required The property name established in Modernizr.addTest It must be lowercase, without any punctuation
tags optional A group that encapsulates many feature detects
caniuse optional A conversion table of caniuse and Modernizr Consider adding caniuse testing
authors optional List of contributors of the script
builderAliases optional Used by CI and the web when tests are renamed Should not be needed in new tests
polyfills optional Available polyfills for not working versions Check the polyfills section
aliases optional Used if a feature has more than a canonical name Legacy only - do not use
async optional If the test supports async functionality Defaults to false
warnings optional Notes to the developer using the script Don't mistake it for knownBugs
knownBugs optional Bugs known of the test (e.g.: doesn't work in IE6)
notes optional Links to resources

Polyfills

Polyfills can be included in the metadata with a simple word. In order to do this the lib/polyfills.json must include the description of all polyfills.

Polyfill Schema

The following example represents the schema in which polyfills must be defined in the polyfills.json file:

json
"css3pie": {
  "name": "CSS3 PIE",
  "authors": ["Jason Johnston"],
  "href": "http://css3pie.com/",
  "licenses": ["Apache2", "GPL2"],
  "notes": ["CSS3 decoration rendering for IE 6-9. Supports: border-radius, box-shadow, multiple backgrounds, linear gradients, border-image"]
},

Metadata does no need to appear in a set order, however, it is common to follow the order stated above.

Polyfill Item Description

Necessity Description
name required The name of the polyfill
authors optional Main authors of the polyfill
notes optional Extra information
href required Link to the polyfill main page
licenses required License of the polyfill

To reference the polyfill in the metadata use the head of the object, in this case css3pie

Submitting a PR

Once you have a feature or bug fix ready commit it to your own branch and submit a PR! There are no requirements to send a PR, no CLA, template you have to follow, title requirements, etc. However, provide a descriptive title and description.

If you need to submit an issue, please include the Modernizr and Node version as well as your OS.

Testing

General Testing

After creating your feature detect you'll need to add testing. In order to do it you must head to the lib/config-all.json and include the relative path with root in the feature-detects folder to your test file (without the extension) under the feature-detects section. Here are some examples:

js
// lib/config-all.json
"img/apng", // for "feature-detects/img/apng.js"
"mathml", // for feature-detects/mathml.js

Note that it follows JSON schema in alphabetical order. Also consider adding caniuse testing if possible.

Caniuse Testing

This testing is optional but highly recommended if a caniuse equivalent exists. In order to do it follow this steps:

  1. Firstly, click on the # symbol to the left of the name of the feature in caniuse.com.
  2. Copy everything in the URL following https://caniuse.com/#feat=, for example, in https://caniuse.com/#feat=channel-messaging copy only channel-messaging.
  3. Add this information to the test/browser/integration/caniuse.js file under the map variable. The Modernizr property value appears in the left and the caniuse value in the right, for example, the channel-messaging corresponds to the messagechannel test so it should appear like this:
js
// test/browser/integration/caniuse.js
messagechannel: 'channel-messaging', // Modernizr left, caniuse right

Note that it follows JSON schema in alphabetical order. Also consider adding caniuse in the metadata field.
The following situations may cause errors: MDN Data, partial supports, flag only support, unknown support.

Verifying and Running Your Tests

There are 2 main ways you can verify if your test works correctly:

Basic checking: If only you want to check that your test returns the correct answer run npm test as it will throw an error if something goes wrong.

Specific checking: In case you want to check the test in a specific browser run npm run serve-gh-pages and navigate to localhost:8080/test/integration.html, where you should find the name of your test in case you performed the General Testing steps right. You will also find the caniuse comparison of your feature detect under the caniuse section (at the bottom) if you performed the Caniuse Testing steps right. You may want to use the search function of your browser.

Install the Basics

Installing Node and Npm

Firstly you will need to install nodejs on your system. Go to nodejs.org and download the latest LTS release. NPM will come along the installer.

In case of being using linux use you may use this DigitalOcean tutorial.

Downloading the Modernizr Repository

Note: It is recommended that you set your own git environment, however this is a complicated and diverse task so we won't be explaining it here. We recommend using, for example, Github Desktop (very beginner friendly), Sublime Merge or the git command-line tool. We also recommend checking this tutorial website if you never used git before.

To download the code of the repository:


File: inch.json

{
"files": {
"included": [
"feature-detects/",
"src/"
],
"excluded": [
"lib/",
"src/html5printshiv.js",
"src/html5shiv.js"
]
}
}


File: package.json

{
"name": "modernizr",
"version": "4.0.0-alpha",
"description": "Modernizr is a JavaScript library that detects HTML5 and CSS3 features in the user’s browser.",
"main": "./lib/cli.js",
"bin": "./bin/modernizr",
"bugs": "https://github.com/Modernizr/Modernizr/issues",
"homepage": "https://github.com/Modernizr/Modernizr",
"repository": "https://github.com/Modernizr/Modernizr.git",
"license": "MIT",
"author": {
"name": "Modernizr",
"url": "https://modernizr.com/"
},
"contributors": [
{
"name": "Faruk Ates",
"url": "https://twitter.com/KuraFire"
},
{
"name": "Paul Irish",
"url": "https://twitter.com/paul_irish"
},
{
"name": "Alex Sexton",
"url": "https://twitter.com/SlexAxton"
},
{
"name": "Ryan Seddon",
"url": "https://twitter.com/ryanseddon"
},
{
"name": "Patrick Kettner",
"url": "https://twitter.com/patrickkettner"
},
{
"name": "Stu Cox",
"url": "https://twitter.com/stucoxmedia"
},
{
"name": "Richard Herrera",
"url": "https://twitter.com/doctyper"
},
{
"name": "Veeck",
"url": "https://twitter.com/hansalbern"
}
],
"dependencies": {
"doctrine": "^3.0.0",
"file": "^0.2.2",
"lodash": "^4.18.1",
"markdown-it": "^14.1.1",
"mkdirp": "^3.0.1",
"requirejs": "^2.3.8",
"yargs": "^17.7.2"
},
"devDependencies": {
"@babel/core": "^7.29.7",
"@babel/preset-env": "^7.29.7",
"@babel/register": "^7.29.7",
"auto-changelog": "^2.6.0",
"chai": "^4.5.0",
"codecov": "^3.8.3",
"del": "^6.1.1",
"eslint": "^8.57.1",
"eslint-plugin-jsdoc": "^50.8.0",
"find-parent-dir": "^0.3.1",
"fs-extra": "^11.4.0",
"globby": "^11.1.0",
"gulp": "^5.0.1",
"gulp-connect": "^5.7.0",
"gulp-eslint": "^6.0.0",
"gulp-pug": "^5.0.0",
"joi": "^18.2.3",
"jquery": "^4.0.0",
"json3": "^3.3.3",
"mocha": "^11.8.0",
"mocha-headless-chrome": "^5.1.0",
"nyc": "^18.0.0",
"proxyquire": "^2.1.3",
"sinon": "^15.2.0",
"ua-parser-js": "^1.0.41"
},
"scripts": {
"--- DEFAULT SCRIPTS ---": "",
"start": "gulp default",
"test": "gulp test",
"--- GULP SCRIPTS ---": "",
"clean": "gulp clean",
"lint": "gulp eslint",
"coverage": "nyc gulp test",
"coverage:lcov": "nyc --reporter=lcov gulp test",
"--- MODERNIZR SCRIPTS ---": "",
"serve-gh-pages": "gulp serve:gh-pages",
"update-gh-pages": "scripts/generate-gh-pages.sh",
"update-changelog": "auto-changelog --commit-limit false --package",
"update-license": "node scripts/generate-license.js && git add LICENSE"
},
"engines": {
"node": ">=16"
},
"files": [
"LICENSE",
"README.md",
"bin/",
"feature-detects/",
"lib/",
"src/"
],
"keywords": [
"modernizr",
"html5",
"css3",
"javascript",
"browser",
"feature detection"
],
"allowScripts": {
"[email protected]": true,
"[email protected]": true
}
}


File: legacy/.coveralls.yml

repo_token: SvXbGOMwbSd26ylxjtyC93P5aSLKX92pq


File: lib/config-all.json

{
"classPrefix": "",
"enableClasses": true,
"enableJSClass": true,
"scriptGlobalName": "window",
"usePrefixes": true,
"minify": false,
"options": [
"addTest",
"atRule",
"domPrefixes",
"hasEvent",
"html5shiv",
"html5printshiv",
"load",
"mq",
"prefixed",
"prefixes",
"prefixedCSS",
"setClasses",
"testAllProps",
"testProp",
"testStyles"
],
"feature-detects": [
"a/download",
"a/aping",
"a/areaping",
"ambientlight",
"applicationcache",
"audio/audio",
"audio/autoplay",
"audio/loop",
"audio/preload",
"audio/webaudio",
"battery/battery",
"battery/lowbattery",
"blob",
"broadcastchannel",
"canvas/canvas",
"canvas/blending",
"canvas/todataurl",
"canvas/winding",
"canvas/text",
"clipboard",
"contenteditable",
"contextmenu",
"cors",
"crypto",
"crypto/getrandomvalues",
"css/all",
"css/animations",
"css/appearance",
"css/aspectratio",
"css/backdropfilter",
"css/backgroundblendmode",
"css/backgroundcliptext",
"css/backgroundposition-shorthand",
"css/backgroundposition-xy",
"css/backgroundrepeat",
"css/backgroundsize",
"css/backgroundsizecover",
"css/borderimage",
"css/borderradius",
"css/boxdecorationbreak",
"css/boxshadow",
"css/boxsizing",
"css/calc",
"css/checked",
"css/chunit",
"css/columns",
"css/cssgrid",
"css/cubicbezierrange",
"css/customproperties",
"css/displayrunin",
"css/displaytable",
"css/ellipsis",
"css/escape",
"css/exunit",
"css/filters",
"css/flexbox",
"css/flexboxlegacy",
"css/flexboxtweener",
"css/flexgap",
"css/flexwrap",
"css/focusvisible",
"css/focuswithin",
"css/fontdisplay",
"css/fontface",
"css/generatedcontent",
"css/gradients",
"css/hairline",
"css/hsla",
"css/hyphens",
"css/invalid",
"css/lastchild",
"css/mask",
"css/mediaqueries",
"css/multiplebgs",
"css/nthchild",
"css/objectfit",
"css/opacity",
"css/overflow-scrolling",
"css/pointerevents",
"css/positionsticky",
"css/pseudoanimations",
"css/pseudotransitions",
"css/reflections",
"css/regions",
"css/remunit",
"css/resize",
"css/rgba",
"css/scrollbars",
"css/scrollsnappoints",
"css/shapes",
"css/siblinggeneral",
"css/subpixelfont",
"css/supports",
"css/target",
"css/textalignlast",
"css/textdecoration",
"css/textshadow",
"css/transforms",
"css/transforms3d",
"css/transformslevel2",
"css/transformstylepreserve3d",
"css/transitions",
"css/userselect",
"css/valid",
"css/variablefonts",
"css/vhunit",
"css/vmaxunit",
"css/vminunit",
"css/vwunit",
"css/will-change",
"css/wrapflow",
"custom-elements",
"custom-protocol-handler",
"dart",
"dataview-api",
"dom/classlist",
"dom/createElement-attrs",
"dom/dataset",
"dom/documentfragment",
"dom/hidden",
"dom/intersection-observer",
"dom/microdata",
"dom/mutationObserver",
"dom/passiveeventlisteners",
"dom/shadowroot",
"dom/shadowrootlegacy",
"elem/bdi",
"elem/details",
"elem/output",
"elem/picture",
"elem/progress-meter",
"elem/ruby",
"elem/template",
"elem/time",
"elem/track",
"elem/unknown",
"emoji",
"es5/array",
"es5/date",
"es5/function",
"es5/object",
"es5/specification",
"es5/strictmode",
"es5/string",
"es5/syntax",
"es5/undefined",
"es6/array",
"es6/arrow",
"es6/class",
"es6/collections",
"es6/generators",
"es6/math",
"es6/number",
"es6/object",
"es6/promises",
"es6/rest-parameters",
"es6/spread-array",
"es6/string-template",
"es6/string",
"es6/symbol",
"es7/array",
"es7/rest-destructuring",
"es7/spread-object",
"es8/object",
"event/customevent",
"event/deviceorientation-motion",
"event/eventlistener",
"event/forcetouch",
"event/hashchange",
"event/oninput",
"event/pointerevents",
"event/proximity",
"file/api",
"file/filesystem",
"flash",
"fullscreen-api",
"gamepad",
"geolocation",
"hiddenscroll",
"history",
"htmlimports",
"ie8compat",
"iframe/sandbox",
"iframe/seamless",
"iframe/srcdoc",
"img/apng",
"img/avif",
"img/crossorigin",
"img/exif-orientation",
"img/jpeg2000",
"img/jpegxr",
"img/lazyloading",
"img/sizes",
"img/srcset",
"img/webp-alpha",
"img/webp-animation",
"img/webp-lossless",
"img/webp",
"input/capture",
"input/fileinput",
"input/fileinputdirectory",
"input/formaction",
"input/formattribute",
"input/formenctype",
"input/formmethod",
"input/formnovalidate",
"input/formtarget",
"input/input",
"input/inputnumber-l10n",
"input/inputsearchevent",
"input/inputtypes",
"input/placeholder",
"input/requestautocomplete",
"input/validation",
"intl",
"json",
"ligatures",
"lists-reversed",
"mathml",
"media-source-extension-api",
"mediaquery/hovermq",
"mediaquery/pointermq",
"messagechannel",
"network/beacon",
"network/connection-effectivetype",
"network/connection",
"network/eventsource",
"network/fetch",
"network/xhr-responsetype-arraybuffer",
"network/xhr-responsetype-blob",
"network/xhr-responsetype-document",
"network/xhr-responsetype-json",
"network/xhr-responsetype-text",
"network/xhr-responsetype",
"network/xhr2",
"notification",
"pagevisibility-api",
"performance",
"pointerlock-api",
"postmessage",
"proxy",
"queryselector",
"link/prefetch",
"requestanimationframe",
"script/async",
"script/defer",
"scrolltooptions",
"serviceworker",
"speech/speech-recognition",
"speech/speech-synthesis",
"storage/cookies",
"storage/indexeddb",
"storage/indexeddbblob",
"storage/indexeddb2",
"storage/localstorage",
"storage/quota-management-api",
"storage/sessionstorage",
"storage/userdata",
"storage/websqldatabase",
"style/scoped",
"svg/svg",
"svg/asimg",
"svg/clippaths",
"svg/filters",
"svg/foreignobject",
"svg/inline",
"svg/smil",
"textarea/maxlength",
"textencoding",
"typed-arrays",
"unicode-range",
"url/bloburls",
"url/data-uri",
"url/parser",
"url/urlsearchparams",
"vibration",
"video/video",
"video/autoplay",
"video/crossorigin",
"video/loop",
"video/preload",
"vml",
"web-intents",
"webanimations",
"webauthn/publickeycredential",
"webgl/webgl",
"webgl/extensions",
"webrtc/datachannel",
"webrtc/getusermedia",
"webrtc/mediastream",
"webrtc/peerconnection",
"websockets",
"websockets/binary",
"window/atob-btoa",
"window/framed",
"window/matchmedia",
"window/pushmanager",
"window/resizeobserver",
"workers/workertypeoption",
"workers/blobworkers",
"workers/dataworkers",
"workers/sharedworkers",
"workers/transferables",
"workers/webworkers",
"xdomainrequest"
]
}


File: lib/polyfills.json

{
"html5shiv": {
"name": "HTML5 Shiv",
"authors": ["Alexander Farkas (@aFarkas)", "Jonathan Neal (@jonathantneal)", "Paul Irish (@paulirish)"],
"href": "https://github.com/aFarkas/html5shiv",
"licenses": ["MIT", "GPL2"],
"notes": ["The HTML5 Shiv enables use of HTML5 sectioning elements in legacy Internet Explorer and provides basic HTML5 styling for Internet Explorer 6-9, Safari 4.x (and iPhone 3.x), and Firefox 3.x."]
},
"html5-notifications": {
"name": "HTML5 Notifications",
"authors": ["Hendrik Beskow"],
"href": "https://gist.github.com/Asmod4n/6030828",
"licenses": ["MIT"],
"notes": ["A Polyfill to fix the differences in WebKit, Blink and Gecko HTML5 Desktop Notifications, also adds a way to add your own JavaScript Notifications in case your Browser doesn't support them natively."]
},
"desktop-notify": {
"name": "HTML5-Desktop-Notifications",
"authors": ["Tsvetan Tsvetkov"],
"href": "https://github.com/ttsvetko/HTML5-Desktop-Notifications",
"licenses": ["Apache2"],
"notes": ["A small library that unifies the HTML5 Notifications APIs across different browsers including IE9 & IE10."]
},
"css3pie": {
"name": "CSS3 PIE",
"authors": ["Jason Johnston"],
"href": "http://css3pie.com/",
"licenses": ["Apache2", "GPL2"],
"notes": ["CSS3 decoration rendering for IE 6-9. Supports: border-radius, box-shadow, multiple backgrounds, linear gradients, border-image"]
},
"dynamicaudiojs": {
"name": "dynamicaudio.js",
"authors": ["Ben Firshman"],
"href": "https://github.com/bfirsh/dynamicaudio.js",
"licenses": ["BSD"],
"notes": []
},
"audiolibjs": {
"name": "audiolib.js",
"authors": ["Jussi Kalliokoski"],
"href": "https://github.com/jussi-kalliokoski/audiolib.js",
"licenses": ["MIT"],
"notes": ["specs: incubator group proposed spec, Mozilla Audio Data API (temporary)"]
},
"transformie": {
"name": "transformie",
"authors": ["Paul Bakaus"],
"href": "https://github.com/pbakaus/transformie",
"licenses": ["GPL2", "MIT"],
"notes": []
},
"csssandpaper": {
"name": "CSS Sandpaper",
"authors": ["Zoltan Hawryluk"],
"href": "https://www.useragentman.com/blog/2010/03/09/cross-browser-css-transforms-even-in-ie/",
"licenses": ["MIT"],
"notes": []
},
"css-escape": {
"name": "CSS.escape()",
"authors": ["Mathias Bynens"],
"href": "https://github.com/mathiasbynens/CSS.escape",
"licenses": ["MIT"],
"notes": []
},
"borderboxmodel": {
"name": "borderBoxModel",
"authors": ["Alberto Gasparin"],
"href": "https://github.com/albertogasparin/borderBoxModel",
"licenses": ["MIT"],
"notes": ["box-sizing: border-box; javascript polyfill for IE6+"]
},
"boxsizingpolyfill": {
"name": "box-sizing-polyfill",
"authors": ["Christian "Schepp" Schaefer"],
"href": "https://github.com/Schepp/box-sizing-polyfill",
"licenses": ["LGPL3"],
"notes": ["box-sizing: border-box; for IE6 and IE7 via Microsoft's proprietary CSS behavior / .htc-script"]
},
"borderbox": {
"name": "Borderbox for Compass",
"authors": ["Richard Herrera"],
"href": "https://github.com/doctyper/compass-borderbox",
"licenses": [],
"notes": ["box-sizing: border-box; polyfill for SASS/Compass. Outputs equivalent CSS for IE6 & 7"]
},
"polyfilter": {
"name": "Polyfilter",
"authors": ["Christian "Schepp" Schaefer"],
"href": "https://github.com/Schepp/CSS-Filters-Polyfill",
"licenses": ["MIT"],
"notes": ["CSS filter effects for Chrome 20+, Safari 6+, Firefox 4+, IE 6 - 9 and some mobile browsers."]
},
"flexie": {
"name": "Flexie",
"authors": ["Richard Herrera"],
"href": "https://github.com/doctyper/flexie",
"licenses": ["MIT"],
"notes": ["Flexible box model - old spec from 2009. (flexbox) Supports: box-orient, box-align, box-direction, box-pack, box-flex, box-ordinal-group"]
},
"es5shim": {
"name": "ES5 Shim",
"href": "https://github.com/kriskowal/es5-shim",
"licenses": ["MIT"]
},
"es5sham": {
"name": "ES5 Sham",
"href": "https://github.com/kriskowal/es5-shim",
"notes": ["Adds the rest of Object, read carefully before using"],
"licenses": ["MIT"]
},
"es6shim": {
"name": "ES6 Shim",
"href": "https://github.com/paulmillr/es6-shim",
"licenses": ["MIT"]
},
"html5gears": {
"name": "html5-gears",
"authors": ["Brad Neuberg"],
"href": "https://code.google.com/archive/p/html5-gears/",
"licenses": ["Apache2"]
},
"blobjs": {
"name": "Blob.js",
"authors": ["Eli Grey"],
"href": "https://github.com/eligrey/Blob.js",
"licenses": ["MIT"]
},
"excanvas": {
"name": "Explorer Canvas",
"authors": ["Erik Arvidsson"],
"href": "https://github.com/arv/explorercanvas",
"licenses": ["Apache2"]
},
"slcanvas": {
"name": "Silverlight HTML 5 Canvas",
"href": "https://archive.codeplex.com/?p=slcanvas",
"licenses": ["Microsoft Public License (Ms-PL)"]
},
"canvastext": {
"name": "canvas-text",
"authors": ["Fabien Ménager"],
"href": "https://code.google.com/archive/p/canvas-text/",
"licenses": ["MIT"]
},
"jquery-contextmenu": {
"name": "jQuery-contextMenu",
"authors": ["Rodney Rehm", "Björn Brala"],
"href": "https://github.com/swisnl/jQuery-contextMenu",
"licenses": ["MIT", "GPL3"]
},
"pmxdr": {
"name": "pmxdr",
"authors": ["Eli Grey"],
"href": "https://github.com/eligrey/pmxdr",
"notes": ["Implements a CORS-compliant cross-domain XMLHttpRequest with postMessage. Note that sites being requested must have a pmxdr host."],
"licenses": ["MIT"]
},
"ppx": {
"name": "postmessage-proxied-xhr",
"authors": ["Atul Varma"],
"href": "https://github.com/toolness/postmessage-proxied-xhr",
"licenses": ["MIT"]
},
"flxhr": {
"name": "flXHR",
"authors": ["Kyle Simpson"],
"href": "https://github.com/flensed/flXHR",
"licenses": ["MIT"]
},
"dropfile": {
"name": "dropfile",
"authors": ["Andrew Dodson"],
"href": "https://github.com/MrSwitch/dropfile",
"licenses": ["MIT"]
},
"moxie": {
"name": "mOxie",
"authors": ["Moxiecode"],
"href": "https://github.com/moxiecode/moxie",
"licenses": ["GPL2"]
},
"fileapi": {
"name": "FileAPI",
"authors": ["Konstantin Lebedev", "Demidov Vladimir"],
"href": "https://github.com/mailru/FileAPI",
"licenses": ["MIT"]
},
"jdataview": {
"name": "jDataView",
"authors": ["Christopher Chedeau", "Ingvar Stepanyan"],
"href": "https://github.com/jDataView/jDataView/",
"licenses": ["WTFPL"]
},
"screenfulljs": {
"name": "screenfull.js",
"authors": ["Sindre Sorhus"],
"href": "https://github.com/sindresorhus/screenfull.js",
"licenses": ["MIT"]
},
"geo-location-javascript": {
"name": "geo-location-javascript",
"authors": ["whoisstan"],
"href": "https://code.google.com/archive/p/geo-location-javascript/",
"notes": ["Mobile-centric: uses non-standard Blackberry and WebOS tricks"],
"licenses": ["MIT"]
},
"geolocation-api-polyfill": {
"name": "Geolocation-API-Polyfill",
"authors": ["Manuel Bieh"],
"href": "https://github.com/manuelbieh/Geolocation-API-Polyfill",
"licenses": ["LGPL"]
},
"jquery-hashchange": {
"name": "jQuery hashchange event",
"authors": ["Ben Alman"],
"href": "http://benalman.com/projects/jquery-hashchange-plugin/",
"licenses": ["MIT", "GPL2"]
},
"moo-historymanager": {
"name": "HistoryManager Mootools Plugin",
"authors": ["Arieh Glazer"],
"href": "https://mootools.net/forge/p/historymanager/",
"licenses": ["MIT"]
},
"jquery-ajaxy": {
"name": "jQuery Ajaxy",
"authors": ["Benjamin Lupton"],
"href": "https://github.com/balupton/jquery-ajaxy",
"licenses": ["MIT"]
},
"hasher": {
"name": "Hasher",
"authors": ["Miller Medeiros"],
"href": "https://github.com/millermedeiros/hasher/",
"licenses": ["MIT"]
},
"shistory": {
"name": "sHistory",
"authors": ["Andrew Udvare"],
"href": "https://github.com/tatsh/sHistory",
"licenses": ["MIT"]
},
"historyjs": {
"name": "History.js",
"authors": ["Benjamin Lupton"],
"href": "https://github.com/browserstate/history.js",
"licenses": ["BSD"]
},
"html5historyapi": {
"name": "HTML5 History API",
"authors": ["Dmitrii Pakhtinov"],
"href": "https://github.com/devote/HTML5-History-API",
"licenses": ["GPL3", "MIT"]
},
"indexeddb": {
"name": "IndexedDB",
"authors": ["Parashuram"],
"href": "https://nparashuram.com/IndexedDBShim/",
"licenses": ["GPL2", "BSD"]
},
"jquerytools": {
"name": "jQuery Tools",
"href": "https://jquerytools.org",
"licenses": ["public domain"]
},
"webshims": {
"name": "Webshims",
"authors": ["Alexander Farkas"],
"href": "https://afarkas.github.io/webshim/demos/",
"licenses": ["MIT"]
},
"h5f": {
"name": "H5F",
"authors": ["Ryan Seddon"],
"href": "https://github.com/ryanseddon/H5F",
"licenses": ["MIT"]
},
"webforms2": {
"name": "Web Forms 2.0",
"authors": ["Weston Ruter"],
"href": "https://github.com/westonruter/webforms2",
"licenses": ["MIT", "GPL2"]
},
"nwxforms": {
"name": "NWX Forms",
"authors": ["Diego Perini"],
"href": "https://github.com/dperini/nwxforms",
"licenses": ["MIT"]
},
"html5formsjs": {
"name": "HTML5Forms.js",
"authors": ["Zoltan Dulac"],
"href": "https://github.com/zoltan-dulac/html5Forms.js"
},
"fdslider": {
"name": "fd-slider",
"authors": ["Brian McAllister"],
"href": "https://github.com/freqdec/fd-slider",
"licenses": ["MIT"]
},
"html5slider": {
"name": "html5slider",
"authors": ["Frank Yan"],
"href": "https://github.com/fryn/html5slider",
"licenses": ["MIT"]
},
"number-polyfill": {
"name": "Number polyfill",
"authors": ["jonstipe"],
"href": "https://github.com/jonstipe/number-polyfill",
"licenses": ["MIT"]
},
"galleryhtml5forms": {
"name": "YUI Gallery HTML5 Forms",
"authors": ["Matt Snider"],
"href": "https://yuilibrary.com/gallery-archive/gallery/show/html5-forms.html",
"licenses": ["BSD"]
},
"jscolor": {
"name": "JSColor",
"authors": ["Johannes Jörg Schmidt"],
"href": "https://github.com/jo/JSColor",
"licenses": ["LGPL"]
},
"html5formshim": {
"name": "HTML5 Form Shim",
"authors": ["Dmitry Sheiko"],
"href": "https://github.com/dsheiko/HTML5-Form-Shim",
"licenses": ["MIT"]
},
"selectedoptionsjs": {
"name": "selectedOptions.js",
"authors": ["Brett Zamir"],
"href": "https://gist.github.com/brettz9/4212217",
"licenses": ["MIT", "GPL", "public domain"]
},
"formvalidationjs": {
"name": "formvalidation.js",
"authors": ["Maksim Chemerisuk"],
"href": "https://github.com/chemerisuk/formvalidation.js",
"licenses": ["MIT"]
},
"json2": {
"name": "JSON2",
"authors": ["Douglas Crockford"],
"href": "https://github.com/douglascrockford/JSON-js",
"licenses": ["public domain"]
},
"mathjax": {
"name": "MathJax",
"authors": ["Davide P. Cervone"],
"href": "https://www.mathjax.org/",
"licenses": ["Apache2"]
},
"visibilityjs": {
"name": "Visibility.js",
"authors": ["Andrey Sitnik"],
"href": "https://github.com/ai/visibility.js",
"licenses": ["GPL3"]
},
"visiblyjs": {
"name": "visibly.js",
"authors": ["Addy Osmani"],
"href": "https://github.com/addyosmani/visibly.js",
"licenses": ["MIT"]
},
"jquery-visibility": {
"name": "Page Visibility shim for jQuery",
"authors": ["Mathias Bynens"],
"href": "https://github.com/mathiasbynens/jquery-visibility",
"licenses": ["MIT", "GPL"]
},
"notificationjs": {
"name": "notification.js",
"authors": ["Andrew Dodson"],
"href": "https://adodson.com/notification.js/",
"licenses": ["MIT"]
},
"perfnow": {
"name": "perf.now() polyfill",
"authors": ["Paul Irish"],
"href": "https://gist.github.com/paulirish/5438650",
"licenses": ["MIT"]
},
"easyxdm": {
"name": "easyXDM",
"authors": ["Sean Kinsey"],
"href": "https://github.com/oyvindkinsey/easyXDM",
"notes": ["Implements XDM and RPC in most browsers since IE6. Also ships with an endpoint for exposing ajax across the domain boundary."],
"licenses": ["MIT"]
},
"postmessage-jquery": {
"name": "postMessage jquery plugin",
"authors": ["Ben Alman"],
"href": "http://benalman.com/projects/jquery-postmessage-plugin/",
"licenses": ["MIT", "GPL2"]
},
"raf": {
"name": "requestAnimationFrame polyfill",
"authors": ["Erik Möller"],
"href": "https://gist.github.com/paulirish/1579671",
"licenses": ["MIT"]
},
"cupcake": {
"name": "CupCake.js",
"authors": ["Rivindu Perera"],
"href": "https://github.com/rivindu/cupcakejs",
"licenses": ["MIT"]
},
"customelements": {
"name": "Custom Elements",
"authors": ["Webcomponents"],
"href": "https://github.com/webcomponents/custom-elements",
"licenses": ["BSD"]
},
"storagepolyfill": {
"name": "Storage Polyfill",
"authors": ["Remy Sharp"],
"href": "https://gist.github.com/remy/350433",
"licenses": ["MIT"]
},
"amplifyjs": {
"name": "Amplify.js",
"authors": ["appendTo"],
"href": "https://amplifyjs.com/",
"licenses": ["MIT", "GPL2"]
},
"yui-cacheoffline": {
"name": "YUI3 CacheOffline",
"authors": ["YUI Team"],
"href": "https://yuilibrary.com/yui/docs/cache/#offline",
"licenses": ["BSD"]
},
"scoped-styles": {
"name": "Scoped Styles",
"authors": ["Simon Madine"],
"notes": ["jQuery Plugin to enable the scoped attribute on style blocks so they only affect their parent element's children."],
"href": "https://github.com/thingsinjars/jQuery-Scoped-CSS-plugin",
"licenses": ["MIT"]
},
"svgweb": {
"name": "SVG Web",
"authors": ["Rick Masters", "Brad Neuberg", "James Hight"],
"href": "https://code.google.com/archive/p/svgweb/",
"licenses": ["Apache2"]
},
"raphael": {
"name": "Raphaël",
"authors": ["Dmitry Baranovsky"],
"href": "http://raphaeljs.com/",
"notes": ["Abstracted API. adds features. fallback for IE via VML"],
"licenses": ["MIT"]
},
"canvg": {
"name": "canvg",
"authors": ["Gabe Lerner"],
"href": "https://github.com/canvg/canvg",
"notes": ["Writes SVG to canvas. Good for Android"],
"licenses": ["MIT"]
},
"svg-boilerplate": {
"name": "SVG Boilerplate",
"authors": ["Robin Berjon"],
"href": "https://github.com/darobin/svgboilerplate",
"notes": ["Alpha and still buggy, but handle multiple concurrent SVG shims together"],
"licenses": ["public domain"]
},
"sie": {
"name": "SIE SVG library",
"authors": ["Hiroki Dehara"],
"href": "https://sie.osdn.jp/",
"notes": ["Fallback to VML for oldIE"],
"licenses": ["Mozilla1.1", "GPL2", "LGPL2.1"]
},
"fabricjs": {
"name": "fabric.js",
"authors": ["Juriy Zaytsev (@kangax)"],
"href": "https://github.com/kangax/fabric.js",
"notes": ["Can render SVG via canvas"],
"licenses": ["MIT"]
},
"inline-svg-polyfill": {
"name": "inline SVG polyfill",
"authors": ["Marc Stalfoort (@mstalfoort)"],
"href": "https://gist.github.com/mstalfoort/1293822",
"licenses": ["MIT"]
},
"joshuabell-polyfill": {
"name": "polyfill",
"authors": ["Joshua Bell"],
"href": "https://github.com/inexorabletash/polyfill",
"licenses": ["various"]
},
"html5media": {
"name": "html5media",
"authors": ["Dave Hall"],
"href": "https://github.com/etianen/html5media",
"licenses": ["GPL3"]
},
"mediaelementjs": {
"name": "MediaElement.js",
"authors": ["John Dyer"],
"href": "https://www.mediaelementjs.com/",
"licenses": ["MIT"]
},
"videojs": {
"name": "video.js",
"authors": ["Steve Heffernan"],
"href": "https://videojs.com/",
"licenses": ["Apache2"]
},
"leanbackplayer": {
"name": "LeanBack Player",
"authors": ["Kapelan Medien GmbH"],
"href": "https://www.leanbackplayer.com/",
"licenses": ["GPL3"]
},
"videoforeverybody": {
"name": "Video For Everybody",
"authors": ["Kroc Camen"],
"href": "http://camendesign.com/code/video_for_everybody",
"licenses": ["public domain"]
},
"jebgl": {
"name": "jebgl",
"authors": ["Martin Qvist"],
"href": "https://code.google.com/archive/p/jebgl/",
"licenses": ["MIT"]
},
"cwebgl": {
"name": "cwebgl",
"authors": ["Cimaron Shanahan"],
"href": "https://code.google.com/archive/p/cwebgl/",
"licenses": ["MIT"]
},
"iewebgl": {
"name": "IEWebGL",
"href": "http://iewebgl.com/",
"licenses": ["MIT"]
},
"sockjs": {
"name": "SockJS",
"authors": ["Bryce Kahle"],
"href": "https://github.com/sockjs/sockjs-client",
"licenses": ["MIT"]
},
"socketio": {
"name": "socket.io",
"authors": ["Guillermo Rauch"],
"href": "https://socket.io/",
"licenses": ["MIT"]
},
"websocketjs": {
"name": "web-socket-js",
"authors": ["Hiroshi Ichikawa"],
"href": "https://github.com/gimite/web-socket-js/",
"licenses": ["BSD"]
},
"atmosphere": {
"name": "atmosphere jQuery plugin",
"authors": ["Jeanfrancois Arcand"],
"href": "https://jfarcand.wordpress.com/2010/06/15/using-atmospheres-jquery-plug-in-to-build-applicationsupporting-both-websocket-and-comet/",
"licenses": ["Apache2"]
},
"graceful-websocket": {
"name": "Graceful WebSocket jQuery plugin",
"authors": ["David Lindkvist"],
"href": "https://github.com/ffdead/jquery-graceful-websocket",
"licenses": ["MIT"]
},
"portal": {
"name": "Portal",
"authors": ["Donghwan Kim"],
"href": "https://github.com/flowersinthesand/portal",
"licenses": ["Apache2"]
},
"datachannel": {
"name": "DataChannel",
"authors": ["Jesús Leganés Combarro"],
"href": "https://github.com/piranna/DataChannel-polyfill",
"licenses": ["GPL3"]
},
"getusermedia": {
"name": "getUserMedia.js",
"authors": ["Addy Osmani"],
"href": "https://github.com/addyosmani/getUserMedia.js",
"licenses": ["MIT"]
},
"fakeworker": {
"name": "fakeworker.js",
"authors": ["Shumpei Shiraishi"],
"href": "https://code.google.com/archive/p/fakeworker-js/",
"licenses": ["Apache2"]
},
"html5shims": {
"name": "web worker api shim",
"authors": ["Jonathan 'J5' Cook"],
"href": "https://code.google.com/archive/p/html5-shims/",
"licenses": ["Apache2"]
},
"webanimationsjs": {
"name": "web-animations-js",
"authors": ["web-animations"],
"href": "https://github.com/web-animations/web-animations-js",
"licenses": ["Apache2"]
},
"shumway": {
"name": "JavaScript Flash VM",
"authors": ["Mozilla Foundation"],
"href": "https://github.com/mozilla/shumway",
"licenses": ["Apache2"]
},
"maxlength": {
"name": "maxlength plugin",
"authors": ["Remy Sharp"],
"href": "https://remysharp.com/2008/06/30/maxlength-plugin/",
"licenses": ["CC SA"]
},
"weakmap": {
"name": "ES6 WeakMap",
"authors": ["Google Inc."],
"href": "https://github.com/Polymer/WeakMap",
"licenses": ["BSD"]
},
"eventlistener": {
"name": "EventListener",
"authors": ["Jonathan Neal"],
"href": "https://github.com/jonathantneal/EventListener",
"licenses": ["MIT"]
},
"es6promises": {
"name": "ES6-Promises",
"authors": ["Jake Archibald"],
"href": "https://github.com/jakearchibald/ES6-Promises",
"licenses": ["MIT"]
},
"es6symbol":{
"name": "ES6-Symbol",
"authors": ["Mariusz Nowak"],
"href": "https://github.com/medikoo/es6-symbol",
"licenses": ["ISC"]
},
"urlparser": {
"authors": ["Google Inc."],
"href": "https://github.com/Polymer/URL",
"licenses": ["BSD"],
"name": "Polymer URL parser polyfill"
},
"css-selector-engine": {
"name": "CSS Selector Engine",
"authors": ["Егор Халимоненко"],
"href": "https://github.com/termi/CSS_selector_engine",
"licenses": ["MIT"]
},
"mutationobservers": {
"authors": ["Google Inc."],
"href": "https://github.com/Polymer/MutationObservers",
"licenses": ["BSD"],
"name": "Mutation Observers polyfill"
},
"polymer-htmlimports": {
"authors": ["Google Inc."],
"href": "https://github.com/polymer/HTMLImports",
"licenses": ["BSD"],
"name": "Polymer HTMLImports polyfill"
},
"matchmediajs": {
"authors": ["Scott Jehl", "Paul Irish", "Nicholas Zakas"],
"href": "https://github.com/paulirish/matchMedia.js/",
"licenses": ["MIT"],
"name": "matchMedia.js"
},
"fetch": {
"authors": ["Github"],
"href": "https://github.com/github/fetch",
"licenses": ["MIT"],
"name": "window.fetch polyfill"
},
"base64js": {
"authors": ["David Chambers"],
"href": "https://github.com/davidchambers/Base64.js",
"licenses": ["Apache2", "WTFPL"],
"name": "window.atob and window.btoa polyfill"
},
"scrollsnap": {
"authors": ["Clemens Krack"],
"href": "https://github.com/ckrack/scrollsnap-polyfill",
"licenses": ["MIT"],
"name": "scrollsnap-polyfill.js"
},
"pep": {
"authors": ["jQuery Foundation and other contributors"],
"href": "https://github.com/jquery/PEP",
"licenses": ["MIT"],
"name": "pep.js"
},
"harmony-reflect": {
"name": "Proxy Object Polyfill",
"authors": ["Tom Van Cutsem"],
"href": "https://github.com/tvcutsem/harmony-reflect",
"licenses": ["Apache2"]
},
"avifjs": {
"name": "Avif.js",
"authors": ["Kagami"],
"href": "https://github.com/Kagami/avif.js",
"licenses": ["CC0"]
}
}


File: test/browser/sauce-browsers.json

[
{
"browserName": "microsoftedge",
"platform": "WIN10",
"version": "20.10240"
},

{
"browserName": "internet explorer",
"platform": "XP",
"version": "7"
}, {
"browserName": "internet explorer",
"platform": "WIN7",
"version": "8"
}, {
"browserName": "internet explorer",
"platform": "WIN7",
"version": "9"
}, {
"browserName": "internet explorer",
"platform": "WIN8",
"version": "10"
}, {
"browserName": "internet explorer",
"platform": "WIN10",
"version": "11"
},

{
"browserName": "firefox",
"platform": "WIN8",
"version": "3.6"
}, {
"browserName": "firefox",
"platform": "WIN8",
"version": "35"
}, {
"browserName": "firefox",
"platform": "WIN8",
"version": "36"
}, {
"browserName": "firefox",
"platform": "WIN8",
"version": "37"
}, {
"browserName": "firefox",
"version": "beta"
},

{
"browserName": "opera",
"platform": "Linux",
"version": "12"
},

{
"browserName": "chrome",
"platform": "WIN8",
"version": "39"
}, {
"browserName": "chrome",
"platform": "WIN8",
"version": "40"
}, {
"browserName": "chrome",
"platform": "WIN8",
"version": "41"
}, {
"browserName": "chrome",
"platform": "WIN8",
"version": "beta"
}, {
"browserName": "chrome",
"platform": "WIN8",
"version": "dev"
},

{
"browserName": "safari",
"platform": "OS X 10.8",
"version": "6"
}, {
"browserName": "safari",
"platform": "OS X 10.9",
"version": "7"
}, {
"browserName": "safari",
"platform": "OS X 10.10",
"version": "8"
}
]


File: .github/CODE_OF_CONDUCT.md

Contributor Covenant Code of Conduct

Our Pledge

In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, gender identity and expression, level of experience,
nationality, personal appearance, race, religion, or sexual identity and
orientation.

Our Standards

Examples of behavior that contributes to creating a positive environment
include:

  • Using welcoming and inclusive language
  • Being respectful of differing viewpoints and experiences
  • Gracefully accepting constructive criticism
  • Focusing on what is best for the community
  • Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

  • The use of sexualized language or imagery and unwelcome sexual attention or
    advances
  • Trolling, insulting/derogatory comments, and personal or political attacks
  • Public or private harassment
  • Publishing others' private information, such as a physical or electronic
    address, without explicit permission
  • Other conduct which could reasonably be considered inappropriate in a
    professional setting

Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable
behavior and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviors that they deem inappropriate,
threatening, offensive, or harmful.

Scope

This Code of Conduct applies both within project spaces and in public spaces
when an individual is representing the project or its community. Examples of
representing a project or community include using an official project e-mail
address, posting via an official social media account, or acting as an appointed
representative at an online or offline event. Representation of a project may be
further defined and clarified by project maintainers.

Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported by contacting the project team at [email protected]. All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.

Attribution

This Code of Conduct is adapted from the Contributor Covenant, version 1.4,
available at http://contributor-covenant.org/version/1/4


File: .github/codecov.yml

comment:
require_changes: true


File: .github/dependabot.yaml

version: 2
updates:

  • package-ecosystem: github-actions
    directory: /
    commit-message:
    prefix: chore
    prefix-development: chore
    schedule:
    interval: monthly

  • package-ecosystem: npm
    directory: /
    commit-message:
    prefix: chore
    prefix-development: chore
    schedule:
    interval: monthly
    cooldown:
    default-days: 1


File: .github/ISSUE_TEMPLATE/---bug-report.md


name: "\U0001F41B Bug report"
about: Report errors with this template
title: ''
labels:
assignees: ''


Type of bug

  • Differences between Can I use & Modernizr
  • False positive
  • Modernizr error

Describe the bug

How to Reproduce

Expected behavior

Additional context


File: .github/ISSUE_TEMPLATE/---test-request.md


name: "\U0001F680 Test request"
about: Suggest a new feature detect
title: ''
labels: detect needed
assignees: ''


Which feature do you want to detect?

Which browsers do support this feature?

How could it be implemented?

Additional context


File: .github/ISSUE_TEMPLATE/good-first-issue.md


name: Good First Issue
about: Intended for explaining little issues. Not intended to be created without knowledge.
title: ''
labels: good first issue
assignees: ''


Hi 👋!
This issue is intended for new contributors and will help you implement your first changes to the Modernizr project.

What is proposed

How to do it

Feel free to raise any question in this issue if you stumble with problems and good luck 💪!


File: .github/ISSUE_TEMPLATE/question.md


name: Questions
about: You don't undestand something? Create an issue!
title: ''
labels:
assignees: ''


The question

Do maintainers need to follow some steps to help you out?


File: .github/workflows/coverage.yml

name: Coverage

on:
push:
branches: [master]
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v7
- name: Installing Node
uses: actions/setup-node@v7
with:
node-version: 24
cache: npm
- name: Installing dependencies
run: npm ci
env:
PUPPETEER_SKIP_DOWNLOAD: true
- name: Installing gulp command line interface
run: npm install gulp-cli
- name: Install Chrome
id: setup-chrome
uses: browser-actions/setup-chrome@v2
with:
chrome-version: latest
- name: Run tests with coverage
run: npm run coverage:lcov
env:
PUPPETEER_EXECUTABLE_PATH: ${{ steps.setup-chrome.outputs.chrome-path }}
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v7
with:
files: ./coverage/lcov.info
token: ${{ secrets.CODECOV_TOKEN }} # required


File: .github/workflows/deploy.yml

name: Deploy to GitHub Pages

on:
push:
tags:
- 'v*' # Run only for tags that start with 'v' (e.g., v1.0, v2.1.3)

jobs:

Build job

build:
# Specify runner + build & upload the static files as an artifact
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v7
- name: Installing Node
uses: actions/setup-node@v7
with:
node-version: 24
cache: npm
- name: Installing dependencies
run: npm ci
- name: Installing gulp command line interface
run: npm install gulp-cli

text
- name: Build static files
    id: build
    run: |
      gulp gh-pages

  - name: Upload static files as artifact
    id: deployment
    uses: actions/upload-pages-artifact@v5
    with:
      path: gh-pages/

Deployment job

deploy:
# Add a dependency to the build job
needs: build

text
# Grant GITHUB_TOKEN the permissions required to make a Pages deployment
permissions:
  pages: write      # to deploy to Pages
  id-token: write   # to verify the deployment originates from an appropriate source

# Deploy to the github-pages environment
environment:
  name: github-pages
  url: ${{ steps.deployment.outputs.page_url }}

# Specify runner + deployment step
runs-on: ubuntu-latest
steps:
  - name: Deploy to GitHub Pages
    id: deployment
    uses: actions/deploy-pages@v5

File: .github/workflows/testing.yml

name: Testing

on:
push:
branches: [master]
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true

jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
node-version: [22.x, 24.x, 26.x]
steps:
- name: Checkout code
uses: actions/checkout@v7
- name: Installing Node ${{ matrix.node-version }}
uses: actions/setup-node@v7
with:
node-version: ${{ matrix.node-version }}
cache: npm
- name: Installing dependencies
run: npm ci
env:
PUPPETEER_SKIP_DOWNLOAD: true
- name: Installing gulp command line interface
run: npm install gulp-cli
- name: Install Chrome
id: setup-chrome
uses: browser-actions/setup-chrome@v2
with:
chrome-version: latest
- name: Run tests
run: npm test -- --no-sandbox --disable-setuid-sandbox
env:
PUPPETEER_EXECUTABLE_PATH: ${{ steps.setup-chrome.outputs.chrome-path }}