Skip to content

chore(remark-lint): skip HTML entirely - #9072

Draft
avivkeller wants to merge 1 commit into
mainfrom
avivkeller-patch-3
Draft

chore(remark-lint): skip HTML entirely#9072
avivkeller wants to merge 1 commit into
mainfrom
avivkeller-patch-3

Conversation

@avivkeller

Copy link
Copy Markdown
Member

The linter (for some reason) get's confused when it sees comments, so we should just skip them

Signed-off-by: Aviv Keller <me@aviv.sh>
Copilot AI review requested due to automatic review settings July 31, 2026 18:17
@avivkeller
avivkeller requested a review from a team as a code owner July 31, 2026 18:17

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@vercel

vercel Bot commented Jul 31, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
nodejs-org Skipped Skipped Jul 31, 2026 6:17pm

Request Review

@cursor

cursor Bot commented Jul 31, 2026

Copy link
Copy Markdown

PR Summary

Low Risk
Narrow lint-rule visitor change in remark-lint with no runtime or security impact; may allow type-like text inside HTML to go unlinted.

Overview
The node-core:invalid-type-reference rule no longer treats html AST nodes as candidates for {type} validation.

isTypeNode now only runs on text nodes. Inline HTML (including HTML comments) is ignored, so comment markup or other HTML fragments are not misread as type references or trigger invalid-type lint noise.

Reviewed by Cursor Bugbot for commit a00395a. Bugbot is set up for automated code reviews on this repo. Configure here.

@codecov

codecov Bot commented Jul 31, 2026

Copy link
Copy Markdown

❌ 1 Tests Failed:

Tests completed Failed Passed Skipped
78 1 77 0
View the top 1 failed test(s) by shortest run time
test::miswrapped reference inside link
Stack Traces | 0.027s run time
[Error [ERR_TEST_FAILURE]: Expected values to be strictly deep-equal:
+ actual - expected

+ []
- [
-   'Type reference must be wrapped in "{}"; saw "<number>"'
- ]
] {
  code: 'ERR_TEST_FAILURE',
  failureType: 'testCodeFailure',
  cause: AssertionError [ERR_ASSERTION]: Expected values to be strictly deep-equal:
  + actual - expected
  
  + []
  - [
  -   'Type reference must be wrapped in "{}"; saw "<number>"'
  - ]
  
      at testRule (file:.../runner/work/nodejs.org/nodejs..../rules/__tests__/utils.mjs:31:10)
      at TestContext.<anonymous> (file:.../runner/work/nodejs.org/nodejs..../rules/__tests__/invalid-type-reference.test.mjs:73:20)
      at Test.runInAsyncScope (node:async_hooks:227:14)
      at Test.run (node:internal/test_runner/test:1325:25)
      at Suite.processPendingSubtests (node:internal/test_runner/test:911:18)
      at Test.postRun (node:internal/test_runner/test:1465:19)
      at Test.run (node:internal/test_runner/test:1390:12)
      at async Suite.processPendingSubtests (node:internal/test_runner/test:911:7) {
    generatedMessage: true,
    code: 'ERR_ASSERTION',
    actual: [],
    expected: [ 'Type reference must be wrapped in "{}"; saw "<number>"' ],
    operator: 'deepStrictEqual',
    diff: 'simple'
  }
}

To view more test analytics, go to the Test Analytics Dashboard
📋 Got 3 mins? Take this short survey to help us improve Test Analytics.

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit a00395a. Configure here.

Comment thread packages/remark-lint/src/rules/invalid-type-reference.mjs
@github-actions

Copy link
Copy Markdown
Contributor

📦 Build Size Comparison

Summary

Metric Value
Old Total First Load JS 7.16 MB
New Total First Load JS 7.16 MB
Delta 0 B (0.00%)

@avivkeller
avivkeller marked this pull request as draft August 1, 2026 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants