Skip to content
Permalink
Browse files

Update typescript-export.js

  • Loading branch information
DenisCarriere committed Oct 27, 2017
1 parent a9a6216 commit 25a1eb4a79b96b0bbd2b54e449991cd8e055f688
Showing with 1 addition and 1 deletion.
  1. +1 −1 rollup-plugins/typescript-export.js
@@ -4,7 +4,7 @@ export default function () {
name: 'typescript-export',
transformBundle(code) {
code = code.trim();
const name = code.match(/module.exports = (\w+)/);
const name = code.match(/module.exports = ([\w$]+);/);
if (name) code += `\nmodule.exports.default = ${name[1]};\n`;
return code;
}

0 comments on commit 25a1eb4

Please sign in to comment.
You can’t perform that action at this time.