Last active
February 24, 2017 15:30
-
-
Save rubenspgcavalcante/0c4f871e810fc5f8a3b723befc059348 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
import $script from "scriptjs"; | |
export default function importAsync(url) { | |
return new Promise((resolve, reject) => { | |
$script(url, resolve); //just a simple, version. You should tread the reject case | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment