summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYukai Huang2016-10-09 21:08:33 +0800
committerYukai Huang2016-10-09 21:08:33 +0800
commit5355da09606035d3fcb05cc3bccc13e4ff888a91 (patch)
tree7087818d2fe6bd3096c8060d131cec8c4d4d663d
parentd0997ed0c18de0f17ea2f9435558f88e3f0fdd1c (diff)
Workaround for circular require
Diffstat (limited to '')
-rw-r--r--public/js/pretty.js8
1 files changed, 6 insertions, 2 deletions
diff --git a/public/js/pretty.js b/public/js/pretty.js
index ebdec2a9..6b551c17 100644
--- a/public/js/pretty.js
+++ b/public/js/pretty.js
@@ -1,4 +1,4 @@
-var extra = require('./extra')
+var extra = require('./extra');
var md = extra.md;
var finishView = extra.finishView;
var autoLinkify = extra.autoLinkify;
@@ -124,6 +124,10 @@ function scrollToBottom() {
}, 100, "linear");
}
+window.scrollToTop = scrollToTop;
+window.scrollToBottom = scrollToBottom;
+
module.exports = {
- scrollToBottom: scrollToBottom
+ scrollToBottom: scrollToBottom,
+ scrollToTop: scrollToTop
}