| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 0b9ef68 commit 62889d7
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -255,9 +255,8 @@ This property is experimental and can change in the future. It should only be us | |||
| 255 | 255 | by tools converting ES modules into CommonJS modules, following existing ecosystem | |
| 256 | 256 | conventions. Code authored directly in CommonJS should avoid depending on it. | |
| 257 | 257 | ||
| 258 | - When an ES Module contains both named exports and a default export, the result returned by `require()` | ||
| 259 | - is the [module namespace object][], which places the default export in the `.default` property, similar to | ||
| 260 | - the results returned by `import()`. | ||
| 258 | + The result returned by `require()` is the [module namespace object][], which places | ||
| 259 | + the default export in the `.default` property, similar to the results returned by `import()`. | ||
| 261 | 260 | To customize what should be returned by `require(esm)` directly, the ES Module can export the | |
| 262 | 261 | desired value using the string name `"module.exports"`. | |
| 263 | 262 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments