Skip to content
This repository has been archived by the owner on Feb 21, 2024. It is now read-only.

Commit

Permalink
Fix invalid usage of import/export (adopted-ember-addons#221)
Browse files Browse the repository at this point in the history
The combination of the way object-transforms.js is authored and the way it's consumed within this addon is not actually valid Javascript! Importing the default export from a module *does not* give you all the individual named imports in a handy container.

The code only happens to work because Ember's loader is being lenient and doesn't really follow the ECMA module spec.

But this code will break under any spec-compliant module loader, including embroider.
  • Loading branch information
ef4 authored and poteto committed Mar 19, 2019
1 parent 8d8c8e5 commit c933c99
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions addon/utils/object-transforms.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,3 +45,7 @@ export function isPresent(objectInstance) {

return !!keys.length;
}

export default {
compact, without, only, isPresent
}

0 comments on commit c933c99

Please sign in to comment.