detect-it
Advanced tools
Comparing version 3.0.6 to 3.0.7
{ | ||
"name": "detect-it", | ||
"version": "3.0.6", | ||
"version": "3.0.7", | ||
"description": "Detect if a device is mouse only, touch only, or hybrid", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -1,8 +0,10 @@ | ||
# Detect It | ||
# Detect It - v3 | ||
> The most recent version of [`detect-it` is available here](https://github.com/rafgraph/detect-it) | ||
Detect if a device is mouse only, touch only, or hybrid, and if it supports passive event listeners. | ||
[Live detection test][liveDetectionTest] | ||
[Live detection test for v3][liveDetectionTest] | ||
![npm](https://img.shields.io/npm/dm/detect-it) | ||
[![npm](https://img.shields.io/npm/dm/detect-it?label=npm)](https://www.npmjs.com/package/detect-it) [![npm bundle size (version)](https://img.shields.io/bundlephobia/minzip/detect-it/3?color=purple)](https://bundlephobia.com/result?p=detect-it@3) | ||
@@ -13,4 +15,2 @@ Exports a reference to a singleton object (a micro state machine with an update function) with its state set to if the device is mouse only, touch only, or hybrid (and other related info about the device), as well as an `update()` function which updates the object's state. | ||
Note that Detect It has removed support for Pointer Events detection because they're just not relevant enough (support for less than 60% of users, [see Can I Use][canIUsePointerEvents], and not supported by React). If you need Pointer Events detection, use [Detect It v1.1][detectItv1.1]. | ||
### `detectIt` micro state machine | ||
@@ -170,3 +170,3 @@ ```javascript | ||
<!-- links --> | ||
[liveDetectionTest]: https://detect-it.rafgraph.dev/ | ||
[liveDetectionTest]: https://detect-it-v3.rafgraph.dev/ | ||
@@ -173,0 +173,0 @@ [detectHoverRepo]: https://github.com/rafgraph/detect-hover |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
20315
0