Skip to content

Commit

Permalink
fix: remove module. prefix for non-default exports;
Browse files Browse the repository at this point in the history
- module.exports[key] === exports[key]
- enter via #3
  • Loading branch information
lukeed committed Aug 19, 2020
1 parent 26bdffa commit e6ed34e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ function run(filepath, isMode) {

if (keys.length > 0) {
keys.sort().forEach(key => {
CJS += `\nmodule.exports.${key} = ${key};`;
CJS += `\nexports.${key} = ${key};`;
});
}

Expand Down

0 comments on commit e6ed34e

Please sign in to comment.