Comparing version 1.1.0 to 1.1.1
{ | ||
"name": "checkcss", | ||
"version": "1.1.0", | ||
"version": "1.1.1", | ||
"type": "module", | ||
@@ -12,3 +12,3 @@ "description": "Utility method for warning when elements have a `class` attribute that refers to an undefined CSS class", | ||
"type": "git", | ||
"url": "https://github.com/broofa/BroofaJS/tree/master/checkcss" | ||
"url": "https://github.com/broofa/checkcss" | ||
}, | ||
@@ -15,0 +15,0 @@ "keywords": [ |
@@ -10,7 +10,7 @@ | ||
* `monitorCSS()` Sets up a | ||
[MutationObserver](https://developer.mozilla.org/en-US/docs/Web/API/MutationObserver) to continuously monitor DOM changes, looking for elements tha treference undefined CSS classes. (Useful for React apps, single-page apps that dynamically update the DOM.) | ||
[MutationObserver](https://developer.mozilla.org/en-US/docs/Web/API/MutationObserver) to continuously monitor DOM changes, looking for elements that reference undefined CSS classes. | ||
(Note: `monitorCSS()` pretty efficient but is probably not something you want to be running in production.) | ||
(Note: `monitorCSS()` is fairly efficient but is probably not something you want to be | ||
running in production.) | ||
## Installation | ||
@@ -25,4 +25,7 @@ | ||
```javascript | ||
import checkCSS, { monitorCSS } from 'checkcss'; | ||
import checkCSS, { ignoreCSS, monitorCSS } from 'checkcss'; | ||
// (optional) Set a regex for classnames to ignore | ||
ignoreCSS(/^license-|^maintainer-/); | ||
// Check current DOM | ||
@@ -29,0 +32,0 @@ checkCSS(); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Mixed license
License(Experimental) Package contains multiple licenses.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4688
4
35
1