feat: use es2015 syntax to re-export default export (#32)
BREAKING CHANGE: This changes the output generated by create-index and can effect CI if it runs linting tests against create-index.
This commit is contained in:
committed by
Gajus Kuizinas
parent
893d9931d4
commit
65892e3bb8
@@ -14,7 +14,7 @@ const buildExportBlock = (files) => {
|
||||
let importBlock;
|
||||
|
||||
importBlock = _.map(files, (fileName) => {
|
||||
return 'export ' + safeVariableName(fileName) + ' from \'./' + fileName + '\';';
|
||||
return 'export { default as ' + safeVariableName(fileName) + ' } from \'./' + fileName + '\';';
|
||||
});
|
||||
|
||||
importBlock = importBlock.join('\n');
|
||||
|
||||
Reference in New Issue
Block a user