From 31fc750dc15fb730e43a2e21b4ec83f8e814fd19 Mon Sep 17 00:00:00 2001 From: Matt Huntington Date: Tue, 2 May 2017 13:15:08 -0400 Subject: [PATCH] imports --- js/index.js | 4 ++++ js/mylib.js | 9 +++++++++ 2 files changed, 13 insertions(+) create mode 100644 js/mylib.js diff --git a/js/index.js b/js/index.js index f02974d..7ee5621 100644 --- a/js/index.js +++ b/js/index.js @@ -1 +1,5 @@ +import asdf, {myFunc2} from './mylib.js' + +asdf(); +myFunc2(); console.log('awesome'); diff --git a/js/mylib.js b/js/mylib.js new file mode 100644 index 0000000..eb50a82 --- /dev/null +++ b/js/mylib.js @@ -0,0 +1,9 @@ +const myFunc = function(){ + console.log('included!'); +} + +export default myFunc; + +export const myFunc2 = function(){ + console.log('also included'); +}