| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 866d646 commit 51ced0f
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1546,7 +1546,7 @@ E('ERR_REQUIRE_ESM', | |||
| 1546 | 1546 | msg += `\n${basename} is treated as an ES module file as it is a .js ` + | |
| 1547 | 1547 | 'file whose nearest parent package.json contains "type": "module" ' + | |
| 1548 | 1548 | 'which declares all .js files in that package scope as ES modules.' + | |
| 1549 | - `\nInstead rename ${basename} to end in .cjs, change the requiring ` + | ||
| 1549 | + `\nInstead either rename ${basename} to end in .cjs, change the requiring ` + | ||
| 1550 | 1550 | 'code to use dynamic import() which is available in all CommonJS ' + | |
| 1551 | 1551 | 'modules, or change "type": "module" to "type": "commonjs" in ' + | |
| 1552 | 1552 | `${packageJsonPath} to treat all .js files as CommonJS (using .mjs for ` + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -31,7 +31,7 @@ describe('CJS ↔︎ ESM interop warnings', { concurrency: true }, () => { | |||
| 31 | 31 | ); | |
| 32 | 32 | assert.ok( | |
| 33 | 33 | stderr.replaceAll('\r', '').includes( | |
| 34 | - `Instead rename ${basename} to end in .cjs, change the requiring ` + | ||
| 34 | + `Instead either rename ${basename} to end in .cjs, change the requiring ` + | ||
| 35 | 35 | 'code to use dynamic import() which is available in all CommonJS ' + | |
| 36 | 36 | `modules, or change "type": "module" to "type": "commonjs" in ${pjson} to ` + | |
| 37 | 37 | 'treat all .js files as CommonJS (using .mjs for all ES modules ' + | |
| Back | FazBrowse Home | New Git URL |
0 commit comments