From f03fed8e237fb66542de2acb0831bd8d58083c57 Mon Sep 17 00:00:00 2001 From: Taye Adeyemi Date: Fri, 13 Apr 2018 10:18:07 +0200 Subject: [PATCH] index: fix export --- index.js | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/index.js b/index.js index 31732ef1f..bf7993720 100644 --- a/index.js +++ b/index.js @@ -7,13 +7,11 @@ * See https://github.com/taye/interact.js/issues/187 */ -import { init } from '@interactjs/interact'; +import { interact, init } from '@interactjs/interact'; -const exported = typeof window === 'undefined' - ? window => { - return init(window); - } - : init(window); +const exported = typeof window === 'object' + ? interact + : init; export default exported;