1
0
mirror of https://github.com/ruanyf/es6tutorial.git synced 2025-05-24 02:02:21 +00:00

Update module-loader.md

fix: 内容修正
This commit is contained in:
liliangrong777 2024-04-10 17:32:06 +08:00 committed by GitHub
parent fc58b0c150
commit 79e15346b2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -397,7 +397,7 @@ import submodule from './node_modules/es-module-package/private-module.js';
}
```
由于`exports`字段只有支持 ES6 的 Node.js 才认识,所以可以用来兼容旧版本的 Node.js。
由于`exports`字段只有支持 ES6 的 Node.js 才认识,所以可以用`main`字段来兼容旧版本的 Node.js。
```javascript
{