chore: restore better node compatibility#610
Conversation
🦋 Changeset detectedLatest commit: f7c5363 The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #610 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 19 19
Lines 273 273
Branches 53 52 -1
=========================================
Hits 273 273 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
This PR updates the internal assertion import style to improve Node.js module compatibility by avoiding node:assert/strict and instead using the strict export from node:assert.
Changes:
- Switch
import { ok as assert } from 'node:assert/strict'toimport { strict as assert } from 'node:assert'. - Update all call sites from
assert(...)toassert.ok(...)to match the new import shape.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| packages/eslint-mdx/src/worker.ts | Updates Node assert import and adjusts assertion calls in the MDX worker pipeline. |
| packages/eslint-mdx/src/tokens.ts | Updates Node assert import and adjusts assertion calls in token restoration logic. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Initial checklist
Description of changes
Follow up #600 which breaks Node 14 compatibility unexpectedly although we announced Node 18+ required. Mostly for
eslint-plugin-prettier.