Skip to content

Commit

Permalink
Merge pull request #87 from fbrosda/import-default-cli
Browse files Browse the repository at this point in the history
Simple workaround for default export of cli.js
  • Loading branch information
pmowrer authored Mar 31, 2020
2 parents 4732edb + 7d6cc2d commit 7843e47
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/cli.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,9 @@
import jsonImporter from './index';
export default jsonImporter();

// Super-hacky: Override Babel's transpiled export to provide both
// a default CommonJS export and named exports.
// Fixes: https://github.com/Updater/node-sass-json-importer/issues/32
// TODO: Remove in 3.0.0. Upgrade to Babel6.
module.exports = exports.default;
Object.keys(exports).forEach(key => module.exports[key] = exports[key]);

0 comments on commit 7843e47

Please sign in to comment.