ember-eslint-parser 0.5.5 → 0.5.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ember-eslint-parser",
3
- "version": "0.5.5",
3
+ "version": "0.5.7",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "repository": {
@@ -23,6 +23,7 @@
23
23
  "content-tag": "^2.0.1",
24
24
  "eslint-scope": "^7.2.2",
25
25
  "html-tags": "^3.3.1",
26
+ "mathml-tag-names": "^2.1.3",
26
27
  "svg-tags": "^1.0.0"
27
28
  },
28
29
  "devDependencies": {
@@ -5,6 +5,7 @@ const { visitorKeys: glimmerVisitorKeys } = require('@glimmer/syntax');
5
5
  const { Reference, Scope, Variable, Definition } = require('eslint-scope');
6
6
  const htmlTags = require('html-tags');
7
7
  const svgTags = require('svg-tags');
8
+ const mathMLTags = require('mathml-tag-names');
8
9
 
9
10
  let TypescriptScope = null;
10
11
  try {
@@ -489,7 +490,7 @@ module.exports.convertAst = function convertAst(result, preprocessedResult, visi
489
490
  if we do not find a variable we register it with a missing variable if
490
491
  * it starts with upper case, it should be a component with a reference
491
492
  * it includes a dot, it's a path which should have a reference
492
- * it's NOT a standard html or svg tag, it should have a referenced variable
493
+ * it's NOT a standard html, svg or mathml tag, it should have a referenced variable
493
494
  */
494
495
  const ignore =
495
496
  // Local instance access
@@ -507,7 +508,9 @@ module.exports.convertAst = function convertAst(result, preprocessedResult, visi
507
508
  const registerUndef =
508
509
  isUpperCase(n.name[0]) ||
509
510
  node.name.includes('.') ||
510
- (!htmlTags.includes(node.name) && !svgTags.includes(node.name));
511
+ (!htmlTags.includes(node.name) &&
512
+ !svgTags.includes(node.name) &&
513
+ !mathMLTags.includes(node.name));
511
514
 
512
515
  if (!ignore && (variable || registerUndef)) {
513
516
  registerNodeInScope(n, scope, variable);
@@ -13,7 +13,7 @@ module.exports = {
13
13
  registerParsedFile(f) {
14
14
  parsedFiles.add(f);
15
15
  },
16
- preprocess: null,
16
+ preprocess: undefined,
17
17
  postprocess: (messages, fileName) => {
18
18
  const msgs = messages.flat();
19
19
  if (!parsedFiles.has(fileName)) {