@herb-tools/linter 0.9.1 → 0.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/herb-lint.js +26 -26
- package/dist/herb-lint.js.map +1 -1
- package/dist/index.cjs +9 -16
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +3 -16
- package/dist/index.js.map +1 -1
- package/dist/lint-worker.js +24 -24
- package/dist/lint-worker.js.map +1 -1
- package/dist/loader.cjs +17 -17
- package/dist/loader.cjs.map +1 -1
- package/dist/loader.js +17 -17
- package/dist/loader.js.map +1 -1
- package/dist/rules/rule-utils.js +1 -13
- package/dist/rules/rule-utils.js.map +1 -1
- package/dist/types/rules/rule-utils.d.ts +1 -5
- package/package.json +7 -7
- package/src/rules/rule-utils.ts +1 -14
package/dist/loader.cjs
CHANGED
|
@@ -2327,7 +2327,7 @@ class Token {
|
|
|
2327
2327
|
}
|
|
2328
2328
|
|
|
2329
2329
|
// NOTE: This file is generated by the templates/template.rb script and should not
|
|
2330
|
-
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.
|
|
2330
|
+
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.2/templates/javascript/packages/core/src/errors.ts.erb
|
|
2331
2331
|
class HerbError {
|
|
2332
2332
|
type;
|
|
2333
2333
|
message;
|
|
@@ -23648,7 +23648,7 @@ function deserializePrismNode(bytes, source) {
|
|
|
23648
23648
|
}
|
|
23649
23649
|
|
|
23650
23650
|
// NOTE: This file is generated by the templates/template.rb script and should not
|
|
23651
|
-
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.
|
|
23651
|
+
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.2/templates/javascript/packages/core/src/nodes.ts.erb
|
|
23652
23652
|
class Node {
|
|
23653
23653
|
type;
|
|
23654
23654
|
location;
|
|
@@ -26738,7 +26738,7 @@ class ParseResult extends Result {
|
|
|
26738
26738
|
}
|
|
26739
26739
|
|
|
26740
26740
|
// NOTE: This file is generated by the templates/template.rb script and should not
|
|
26741
|
-
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.
|
|
26741
|
+
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.2/templates/javascript/packages/core/src/node-type-guards.ts.erb
|
|
26742
26742
|
/**
|
|
26743
26743
|
* Type guard functions for AST nodes.
|
|
26744
26744
|
* These functions provide type checking by combining both instanceof
|
|
@@ -27906,6 +27906,19 @@ function createWhitespaceNode() {
|
|
|
27906
27906
|
});
|
|
27907
27907
|
}
|
|
27908
27908
|
|
|
27909
|
+
// https://html.spec.whatwg.org/multipage/common-microsyntaxes.html#boolean-attributes
|
|
27910
|
+
const HTML_BOOLEAN_ATTRIBUTES = new Set([
|
|
27911
|
+
"allowfullscreen", "async", "autofocus", "autoplay", "checked", "compact",
|
|
27912
|
+
"controls", "declare", "default", "defer", "disabled", "formnovalidate",
|
|
27913
|
+
"hidden", "inert", "ismap", "itemscope", "loop", "multiple", "muted",
|
|
27914
|
+
"nomodule", "nohref", "noresize", "noshade", "novalidate", "nowrap",
|
|
27915
|
+
"open", "playsinline", "readonly", "required", "reversed", "scoped",
|
|
27916
|
+
"seamless", "selected", "sortable", "truespeed", "typemustmatch",
|
|
27917
|
+
]);
|
|
27918
|
+
function isBooleanAttribute(attributeName) {
|
|
27919
|
+
return HTML_BOOLEAN_ATTRIBUTES.has(attributeName.toLowerCase());
|
|
27920
|
+
}
|
|
27921
|
+
|
|
27909
27922
|
/*
|
|
27910
27923
|
* The following code is derived from the "js-levenshtein" repository,
|
|
27911
27924
|
* Copyright (c) 2017 Gustaf Andersson (https://github.com/gustf/js-levenshtein)
|
|
@@ -28052,7 +28065,7 @@ function didyoumean(input, list, threshold) {
|
|
|
28052
28065
|
}
|
|
28053
28066
|
|
|
28054
28067
|
// NOTE: This file is generated by the templates/template.rb script and should not
|
|
28055
|
-
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.
|
|
28068
|
+
// be modified manually. See /Users/marcoroth/Development/herb-release-0.9.2/templates/javascript/packages/core/src/visitor.ts.erb
|
|
28056
28069
|
class Visitor {
|
|
28057
28070
|
visit(node) {
|
|
28058
28071
|
if (!node)
|
|
@@ -29448,13 +29461,6 @@ const HTML_VOID_ELEMENTS = new Set([
|
|
|
29448
29461
|
"area", "base", "br", "col", "embed", "hr", "img", "input", "link", "meta",
|
|
29449
29462
|
"param", "source", "track", "wbr",
|
|
29450
29463
|
]);
|
|
29451
|
-
const HTML_BOOLEAN_ATTRIBUTES = new Set([
|
|
29452
|
-
"autofocus", "autoplay", "checked", "controls", "defer", "disabled", "hidden",
|
|
29453
|
-
"loop", "multiple", "muted", "readonly", "required", "reversed", "selected",
|
|
29454
|
-
"open", "default", "formnovalidate", "novalidate", "itemscope", "scoped",
|
|
29455
|
-
"seamless", "allowfullscreen", "async", "compact", "declare", "nohref",
|
|
29456
|
-
"noresize", "noshade", "nowrap", "sortable", "truespeed", "typemustmatch"
|
|
29457
|
-
]);
|
|
29458
29464
|
const HEADING_TAGS = new Set(["h1", "h2", "h3", "h4", "h5", "h6"]);
|
|
29459
29465
|
/**
|
|
29460
29466
|
* SVG elements that use camelCase naming
|
|
@@ -29609,12 +29615,6 @@ function isBlockElement(tagName) {
|
|
|
29609
29615
|
function isVoidElement(tagName) {
|
|
29610
29616
|
return HTML_VOID_ELEMENTS.has(tagName.toLowerCase());
|
|
29611
29617
|
}
|
|
29612
|
-
/**
|
|
29613
|
-
* Checks if an attribute is a boolean attribute
|
|
29614
|
-
*/
|
|
29615
|
-
function isBooleanAttribute(attributeName) {
|
|
29616
|
-
return HTML_BOOLEAN_ATTRIBUTES.has(attributeName.toLowerCase());
|
|
29617
|
-
}
|
|
29618
29618
|
/**
|
|
29619
29619
|
* Attribute visitor that provides granular processing based on both
|
|
29620
29620
|
* attribute name type (static/dynamic) and value type (static/dynamic)
|