A polyfill for the proposed inert API
npm install wicg-inertThe inert attribute/property allows web authors to mark parts of the DOM tree
as inert:
> When a node is inert, then the user agent must act as if the node was absent
> for the purposes of targeting user interaction events, may ignore the node for
> the purposes of text search user interfaces (commonly known as "find in
> page"), and may prevent the user from selecting text in that node.
Furthermore, a node which is inert should also be hidden from assistive
technology.
- Read the Explainer.
- Read the Spec.
- Try the Demo.
- Give feedback!
npm install --save wicg-inert
We recommend only using versions of the polyfill that have been published to
npm, rather than cloning the repo and using the source directly. This helps
ensure the version you're using is stable and thoroughly tested.
This project provides two versions of the polyfill in package.json.
- main: Points at dist/inert.js which is transpiled to ES3.
- module: Points at dist/inert.esm.js which is transpiled to ES3.
_If you do want to build from source, make sure you clone the latest tag!_
```
import "wicg-inert";
OR…
`html
...