-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
replace dynamic imports with static imports for better cross-browser …
…support
- Loading branch information
Showing
2 changed files
with
22 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,6 @@ | ||
const commandModules = [ | ||
//import('./commands/example.js'), | ||
import('./commands/findOutOfAlbumPhotos.js') | ||
]; | ||
//import example from './commands/example.js'; | ||
import findOutOfAlbumPhotos from './commands/findOutOfAlbumPhotos.js'; | ||
|
||
export default Promise.all(commandModules).then(modules => { | ||
// Use default import of modules, | ||
// changing an array of Modules into an array of the actual exports. | ||
return modules.map(m => m.default); | ||
}); | ||
export default [ | ||
findOutOfAlbumPhotos | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters