Skip to content

Commit dc4df4f

Browse files
committed
doc: fix ES module code blocks rendering in modules.md
The two consecutive `mjs` code blocks in the "Loading ECMAScript modules using require()" section were being incorrectly grouped into a CJS/ESM toggle tab by doc-kit's highlighter. Change the language tag from `mjs` to `js` so they render as independent code blocks.
1 parent ae228c1 commit dc4df4f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

doc/api/modules.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -219,12 +219,12 @@ directly.
219219

220220
With the following ES Modules:
221221

222-
```mjs
222+
```js
223223
// distance.mjs
224224
export function distance(a, b) { return Math.sqrt((b.x - a.x) ** 2 + (b.y - a.y) ** 2); }
225225
```
226226

227-
```mjs
227+
```js
228228
// point.mjs
229229
export default class Point {
230230
constructor(x, y) { this.x = x; this.y = y; }

0 commit comments

Comments
 (0)